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
Expand all | Collapse all

dynamic sql date insert

  • 1.  dynamic sql date insert

    Posted Tue November 13, 2007 05:05 AM

    Hi , I’m trying to insert a date into a table using dynamic sql. If I create a dynamic sql adaptor service with no inputs and supply the following sql…
    insert into datetest (field1,field2) values (‘field1value’, to_date(‘2007/11/12 09:35:35’, ‘yyyy/mm/dd hh24:mi:ss’))
    …it works fine.
    However if i create two input fields and supply the values at run time using the following sql…
    insert into datetest (field1,field2) values (‘${field1}’, to_date(‘${field2}’, ‘yyyy/mm/dd hh24:mi:ss’))
    …i get the following error…

    Could not run ‘insertDynamic’.

    com.wm.app.b2b.server.ServiceException: [ART.117.4002] Adapter Runtime (Adapter Service): Unable to invoke adapter service OracleDates.O8i:insertDynamic.
    [ADA.1.316] Cannot execute the SQL statement “insert into datetest (field1,field2)
    values (‘field1value’, to_date(‘2007/11/13 10:40:23’, ‘yyyy/mm/dd hh24:mi:ss’))”. "
    (17003) Invalid column index"
    Invalid column index

    Any ideas?


    #webMethods
    #Adapters-and-E-Standards
    #Integration-Server-and-ESB


  • 2.  RE: dynamic sql date insert

    Posted Tue November 13, 2007 05:07 AM

    p.s. i should have said that I’m using jdbc adaptor 6.5 and I’ve tried it against both an oracle 8i and 10i


    #Integration-Server-and-ESB
    #webMethods
    #Adapters-and-E-Standards