IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  Webmethods 9.9 Impossible to insert row with timestamp column

    Posted Tue October 11, 2016 11:00 AM

    Hi

    I am using a custom JDBC dapter. the relevant bit of the sql request is as follows


    ?,
    to_timestamp_tz(?, ‘YYYY-MM-DD HH24:MI:SS,FF3TZH:TZM’),
    ?,

    I pass the value: 2016-04-14 13:53:27,652+02:00

    I get the error:

    Unable to invoke adapter service …
    NumberFormat Exception for field: DATE_DOCUMENT. Error: For input string: “27,652+02:00”

    I am unable to figure out what I am doing wrong, weirdly the request:

    select to_timestamp_tz(‘2016-04-14 13:53:27,652+02:00’, ‘YYYY-MM-DD HH24:MI:SS,FF3TZH:TZM’) from dual;

    executed in the same oracle database works fine.

    Any suggestions ?

    Best regards


    #Integration-Server-and-ESB
    #webMethods


  • 2.  RE: Webmethods 9.9 Impossible to insert row with timestamp column

    Posted Tue October 11, 2016 04:35 PM

    which version of wM you are using ?

    Set below one as part of extended settings:

    watt.adapter.JDBC.DateWithTimestamp=true
    watt.adapter.JDBC.DateWithTimestampAndMilliseconds=true

    Thanks,


    #Integration-Server-and-ESB
    #webMethods


  • 3.  RE: Webmethods 9.9 Impossible to insert row with timestamp column

    Posted Wed October 12, 2016 09:47 AM

    Hi

    Thanks for your answer
    I am using WM 9.9.

    I kind of stumbled partly on the solution, in case anybody’s interested, I decided to set “Input Field Type” to “SetAstring”, which went well.
    But Still the timezone bit is not inserted into the column but I guess I would have to add a parameter to the Extended Settings such as watt.adapter.JDBC.DateWithTimestampAndMillisecondsAndTimeZone or something.
    Could you tell me where I can find a link to the 9.9 JDBC Adapter guide please ?

    Best regards.


    #Integration-Server-and-ESB
    #webMethods


  • 4.  RE: Webmethods 9.9 Impossible to insert row with timestamp column

    Posted Wed October 12, 2016 01:19 PM

    Hi,

    Was the error coming from the Oracle server or from the Wm adaptor?

    In the latter case, was it waiting to receive a datetime type and you gave it a string? was the string formatted according to the system’s locale definition?

    Best regards,


    #Integration-Server-and-ESB
    #webMethods


  • 5.  RE: Webmethods 9.9 Impossible to insert row with timestamp column

    Posted Wed October 12, 2016 02:29 PM

    Setting “Input Field Type” to “SetAstring” or to “java.lang.String” should work. For documentation kindly refer Empower or SAG Tech Community

    http://techcommunity.softwareag.com/ecosystem/communities/public/webmethods/.links/documentation-webmethods


    #Integration-Server-and-ESB
    #webMethods


  • 6.  RE: Webmethods 9.9 Impossible to insert row with timestamp column

    Posted Wed October 12, 2016 03:49 PM

    Hi

    Eventually I remembered that the timezone bit is down to the column type, not the adapter, so “timestamp” was quickly switched to “timestamp with timezone”, so basically problem solved!

    Thanks everyone.


    #webMethods
    #Integration-Server-and-ESB


  • 7.  RE: Webmethods 9.9 Impossible to insert row with timestamp column

    Posted Wed October 12, 2016 04:25 PM

    Glad to hear issue got solved.

    Can you tell what did you set as part of “InputJDBCType” & “InputFieldType”. Also did you write in ExtendedSettings ?

    Thanks,


    #Integration-Server-and-ESB
    #webMethods


  • 8.  RE: Webmethods 9.9 Impossible to insert row with timestamp column

    Posted Wed October 12, 2016 04:52 PM

    I first tried adding the two parameters to extended Settings but still got the same error.
    Then on a hunch I tried SetAstring instead of String for “Input Field Type” which made it possible to insert the date but still without the timestamp, and then I switched timestamp to timestamp with timezone.

    Best regards


    #webMethods
    #Integration-Server-and-ESB