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.  Inserting a null date to Timestamp in SQL Server

    Posted Sat June 04, 2005 12:12 AM

    Hi, experts! Did anyone successfully insert NULL date to a Timestamp field in SQL Server DB? I can insert non-null values OK, but always get an error when inserting NULL.

    I guess I can choose NOT to insert when value is null, but is there any better solutions, please???


    #Integration-Server-and-ESB
    #Flow-and-Java-services
    #webMethods


  • 2.  RE: Inserting a null date to Timestamp in SQL Server

    Posted Sat June 04, 2005 12:31 AM

    Hi Jin - Yes, we have done this. Have you checked to make sure that the date field allows NULL.


    #Flow-and-Java-services
    #webMethods
    #Integration-Server-and-ESB


  • 3.  RE: Inserting a null date to Timestamp in SQL Server

    Posted Mon June 06, 2005 04:16 PM

    Rajesh, thanks for the post. The date field does allows NULL.

    If I run the INSERT Adapter Service only, and leave the date field blank, the insert will be successful. However, if I run this AS inside another flow service, and map/pass in an empty string or a NULL to date field, the insert will fail.

    There is a workaround, not to insert date field (instead of inserting a NULL), which seems to be working.


    #webMethods
    #Integration-Server-and-ESB
    #Flow-and-Java-services


  • 4.  RE: Inserting a null date to Timestamp in SQL Server

    Posted Mon June 06, 2005 04:22 PM

    Jin,

    Do a Branch Step on the date mapping and see if the data is null then dont map and default map it.This way condition satisfies.

    HTH,
    RMG


    #webMethods
    #Flow-and-Java-services
    #Integration-Server-and-ESB