Uploaded image for project: 'AdMaxLocal'
  1. AdMaxLocal
  2. AML-2886

Merchant can not be saved if character length of contact name is greater than 127

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: Himalaya
    • Fix Version/s: Himalaya
    • Component/s: Reseller UI
    • Labels:
      None
    • Environment:

      QA Environment
      Sapi – Build 722
      Reseller UI – Build 158
      Data Util Jar – Build 126
      Ops Scripts – build 230
      Core – Himalaya Build 2
      BidMgr – Himalaya Build 2

    • Story Points:
      3
    • Sprint:
      Sprint 3

      Description

      Merchant can not saved if character length of contact name is greater than 127

      Steps:

      1.Login to reseller ui

      2.Enter valid details on Merchant information page ;
      suppose contact name length is greater that 127 characters.

      3.Click Save

      Actual Result:

      It shows error window."Error in saving Merchant....",Please see the attached screenshot.

      Snippet of tomcat log:

      16 12:08:09,150-95884561 [http-8080-9] INFO org.apache.cxf.interceptor.LoggingInInterceptor [] - Inbound Message
      ----------------------------
      ID: 1139
      Address: http://127.0.0.1:8080/sapi/rest/merchants
      Encoding: UTF-8
      Http-Method: POST
      Content-Type: application/json; charset=utf-8
      Headers:

      {Accept=[application/json, text/plain], connection=[Keep-Alive], content-encoding=[UTF-8], Content-Length=[851], content-type=[application/json; charset=utf-8], host=[127.0.0.1:8080], user-agent=[Apache-HttpClient/4.2.1 (java 1.5)], x-tsa-authenticate=[LK3CYKUPKK2RWHNRSE7KBWIT23HS2QMSMPWIIWI6HXKC33OEELXCF6EYLIGB74RSU6RHOGCCHXQ6IGAYUEX3DIV6QA6CIRDIXFUISKSYRC5AHD4Y62XEU5M7QFPQP3U4XVK3UCIXPI6B5IQG7XUTKR7FJE2K5CRD7CFHPFQSHW6YZ2WEUIPUXUA5HOZYBQ65HR77HWLZLZM3UBVAZ5R46AFBNWVYGTTAPVG6UKVPQM54KQ3MBWCI2CR2YGOGMLP24RDYT3GTTEYBJH26A7IGE5PQXL6QUUXALQNPLZBEKZDVHHXX2WR443QWUJCWN4NSU6BX5I4GC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WJXTF3QVR44CE2Y4R26M2VAKE7P6FGAFM4LARHCQME46XDARCTZJAUFOFCF6A2TQN53PBZWWWZR64E6U5I25GMVAYQQQGJR7NDIMQ75YYV7FBJKHQXNWVPSYISYQDY4CNYZKPEPVHB4LDR6N6XXK4E2WS5BUDLQ7VEVNL3J4HCCD4FRU7PKF4NL5SSVWRQDPHADSXZ3EQSNEYOJ55TUZTMPUVXJUUPVWBMZLWN7OMSX5GKK5RQIMMTLECNHRXGSDFUHB4VM7A6DKFQ====]}

      Payload: {"comments":"","contact":

      {"active":false,"displayName":"Contact name test bbbbbbbbbbbbaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaatesting","email":"contactnametesting@yahoo.com","language":"en","countryCode":"US","timezone":"America/New_York"}

      ,"contactEmail":"contactnametesting@yahoo.com","contactName":"Contact name test bbbbbbbbbbbbaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaatesting","createdByName":"QAtest","customerId":"Contact Name 12","displayName":"Merchant Test 012","properties":

      {"currencyCode":"USD","locale":"en_US","countryCode":"US","language":"en"}

      ,"realm":"com.thesearchagency/0b1791ae-f4ce-4c04-bb9e-809a28caca01","resellerId":"0b1791ae-f4ce-4c04-bb9e-809a28caca01","active":true}
      --------------------------------------
      2014-05-16 12:08:09,227-95884638 [http-8080-9] ERROR com.thesearchagency.sapi.services.merchant.MerchantService [timezone=Etc/UTC, principalId=9ceaeb2c-37dd-4be0-89b6-a62b4288ec3b, requestId=898fb4f9-d4e9-4bca-bb67-1cb4bf5f819a, locale=en_US, authToken=LK3CYKUPKK2RWHNRSE7KBWIT23HS2QMSMPWIIWI6HXKC33OEELXCF6EYLI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2WFAWIV66TFM37NEHD7TY5AQL6IHVTXOEU2Y2Q6IAC7FNUDHQM72DXFRWCLNJOUGSJOYFQKXJYE32IHNBV4NNOQN3U55UBYX6CIIGWKPSIILXMPVKOWI545MR5AUCNL2AOSN5A7BN3OPKX7O5JHCLX6ZVYVYHKDCJCKYXG6TO7OJQDDX6LFRJAQPA2PXK22SJZ2IRKCNWMWZ3JGW5IEXSVMDFMEZSMGSZREZTWKV4MI5IHW7R4QNJNYOQEIWEWK6IBJCUTWONJJMYDPWJXTF3QVR44CE2Y4R26M2VAKE7P6FGAFM4LARHCQME46XDARCTZJAUFOFCF6A2TQN53PBZWWWZR64E6U5I25GMVAYQQQGJR7NDIMQ75YYV7FBJKHQXNWVPSYISYQDY4CNYZKPEPVHB4LDR6N6XXK4E2WS5BUDLQ7VEVNL3J4HCCD4FRU7PKF4NL5SSVWRQDPHADSXZ3EQSNEYOJ55TUZTMPUVXJUUPVWBMZLWN7OMSX5GKK5RQIMMTLECNHRXGSDFUHB4VM7A6DKFQ====, hostname=127.0.0.1, ipAddress=127.0.0.1] - Exception caught in execution. Data is Merchant(theId=null, theName=null, theDisplayName=Merchant Test 012, theDescription=null, theRealm=com.thesearchagency/0b1791ae-f4ce-4c04-bb9e-809a28caca01, theActiveFlag=true, theCreatedDate=null, theLastModifiedDate=null, theCreatorId=null, theCreatorName=QAtest, theContactName=Contact name test bbbbbbbbbbbbaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaatesting, theLastModifierId=null, theLastModifierName=null, theCustomerId=Contact Name 12, theContactEmail=contactnametesting@yahoo.com, theContactPhoneNumber=, thePhoneNumber=, theComments=, theContact=User(theId=null, theDisplayName=Contact name test bbbbbbbbbbbbaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaatesting, theFirstName=null, theLastName=null, theDescription=null, theOrganization=null, theRealm=null, theEmail=contactnametesting@yahoo.com, theActiveFlag=false, theGender=M, theLanguage=en, theCountry=US, theTimezone=America/New_York, theHomePhone=null, theWorkPhone=, theWorkPhoneExtension=null, theMobilePhone=null, theBirthday=null, theLastLoginDate=null, theCreatedDate=null, theLastModifiedDate=null, theCreatorId=null, theLastModifierId=null, theProperties={}), theURL=null, theGroupId=null, theUserId=null, theResellerId=0b1791ae-f4ce-4c04-bb9e-809a28caca01, theProperties=

      {currencyCode=USD, locale=en_US, countryCode=US, language=en}

      )
      org.springframework.dao.DataIntegrityViolationException: PreparedStatementCallback; SQL [INSERT INTO `merchants` (`id`, `reseller_id`, `customer_id`, `realm_id`, `group_id`, `user_id`, `name`, `display`, `description`, `created_on`, `created_by`, `created_by_name`, `modified_on`, `modified_by`, `modified_by_name`, `active`, `comments`, `url`, `phone`, `contact_name`, `contact_phone`, `contact_email`) values (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)]; Data truncation: Data too long for column 'contact_name' at row 1; nested exception is com.mysql.jdbc.MysqlDataTruncation: Data truncation: Data too long for column 'contact_name' at row 1
      at org.springframework.jdbc.support.SQLStateSQLExceptionTranslator.doTranslate(SQLStateSQLExceptionTranslator.java:101) ~[spring-jdbc-3.1.2.RELEASE.jar:3.1.2.RELEASE]
      at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:72) ~[spring-jdbc-3.1.2.RELEASE.jar:3.1.2.RELEASE]
      at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80) ~[spring-jdbc-3.1.2.RELEASE.jar:3.1.2.RELEASE]
      at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80) ~[spring-jdbc-3.1.2.RELEASE.jar:3.1.2.RELEASE]
      at org.springframework.jdbc.core.JdbcTemplate.execute(JdbcTemplate.java:603) ~[spring-jdbc-3.1.2.RELEASE.jar:3.1.2.RELEASE]
      at org.springframework.jdbc.core.JdbcTemplate.update(JdbcTemplate.java:812) ~[spring-jdbc-3.1.2.RELEASE.jar:3.1.2.RELEASE]
      .
      .
      .
      Caused by: com.mysql.jdbc.MysqlDataTruncation: Data truncation: Data too long for column 'contact_name' at row 1
      at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4118) ~[mysql-connector-java-5.1.23.jar:na]
      at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4052) ~[mysql-connector-java-5.1.23.jar:na]
      at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2503) ~[mysql-connector-java-5.1.23.jar:na]
      at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2664) ~[mysql-connector-java-5.1.23.jar:na]
      at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2794) ~[mysql-connector-java-5.1.23.jar:na]

        Attachments

          Activity

            People

            • Assignee:
              atul.sanagar Atul Sanagar (Inactive)
              Reporter:
              atul.sanagar Atul Sanagar (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: