Announcement

Collapse
No announcement yet.

[SOLVED] Updating with Null values through integration

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • [SOLVED] Updating with Null values through integration

    Hi,

    We are trying to update existing values with null values through integration. If we do any updates with new values, the changes happen in OTM.

    But in case if we pass null values in update, there is no change and the previous values remain.

    One example is we are trying to update the location address:

    Before updation:
    Address line1: xxxxx
    Address line2: xxxxx
    Address line3: xxxxx

    Next we are passing the values as below:
    Address line1: yyyyy
    Address line2: yyyyy
    Address line3: null value.

    But we see in the above, address line3 is not getting updated with the null value.

    Did anyone face similar issue and any idea how you overcome this one?

    Thanks,
    Rajiv


  • #2
    Re: Updating with Null values through integration

    Normally, you can use "~" to null out a field (see Integration Guide - Blank Out Certain Fields section)

    But for your case, you need to set /Transmission/TransmissionBody/GLogXMLElement/Location/TransactionCode=RC to remove and re-create all Address lines.
    --
    Joseph Liang
    MavenWire APAC
    http://www.mavenwire.com/

    Comment


    • #3
      Re: Updating with Null values through integration

      Hi Joseph,

      Thank you very much.

      This worked for us. We were able to null out the address lines with "~".

      We had similar requirement in location role, where we want to remove one of the existing location roles from location. We used "RC" for that and it also worked.

      Regards,
      Rajiv

      Comment


      • #4
        Re: Updating with Null values through integration

        Hi Joseph,

        I want to update date with null values. Tried both transaction code and ~. OTM throws an exception Null GlogDate. I am using version 6.1.

        In integration guide also, I am unable to find any clue on what's wrong? Do I need to update any where else as well?

        Thanks,
        Rajiv

        Comment


        • #5
          Re: Updating with Null values through integration

          If you are in OTM 6.1, please change your XML to include GLogDate element
          Code:
          <TimeWindow>
            <EarlyPickupDt>
              [B]<GLogDate>~</GLogDate>[/B]
            </EarlyPickupDt>
          </TimeWindow>
          Please refer to Metalink Note [ID 1148812.1] Integration Date Format Issue
          --
          Joseph Liang
          MavenWire APAC
          http://www.mavenwire.com/

          Comment


          • #6
            Re: Updating with Null values through integration

            Thanks Joseph.

            This works for updating an existing date with a new date. But when I want to update an existing date with null value, I'm passing "~" and when this reaches OTM, I get the following exception "convertStringToSqlDate failed on ~".

            For updating date with null, Do I need to use any other symbol/code?

            Regards,
            Rajiv

            Comment


            • #7
              Re: Updating with Null values through integration

              Then I would think this could be a bug. You may want to log a SR to Oracle Support.
              --
              Joseph Liang
              MavenWire APAC
              http://www.mavenwire.com/

              Comment


              • #8
                Re: Updating with Null values through integration

                Hi Joseph,

                This works fine when we do the following:

                1. Have the transaction code as RC.
                2. If the date field has to be updated with null, donot pass the tags itself.

                For example,

                <TimeWindow>
                <LatePickupDt>20100729190000</LatePickupDt>
                <EarlyDeliveryDt>20100829190000</EarlyDeliveryDt>
                <LateDeliveryDt>20100829190000</LateDeliveryDt>
                <PickupIsAppt>N</PickupIsAppt>
                <DeliveryIsAppt>N</DeliveryIsAppt>
                </TimeWindow>


                Here I want to update the early pickup date with null and I wouldnot send <EarlyPickupDt> at all. This works in updating null values.

                Thanks,
                Rajiv

                Comment


                • #9
                  Re: Updating with Null values through integration

                  Originally posted by Sachin View Post
                  We have discussed this with our Development Group and confirmed that using a "~" for a date field is not supported. Unfortunately there is no way to Null a Date field. You may submit an enhancement request to suggest such behavior.
                  Hi Joseph,

                  Oracle support team has conveyed "~" is not supported for updating date field with Null values.

                  Regards,
                  Rajiv

                  Comment

                  Working...
                  X