Skip to Content
avatar image
Former Member

Condition based COMMIT of IDocs

Dear All,

I am creating ALEAUD Idocs from an incoming CONTRL or BANSTA file. This incoming file can have multiple BANSTA/CONTRL messages, for which I need to create atleast one ALEAUD(maybe multiple) per BANSTA/CONTRL message. The requirement here is that the IDocs be committed only when all the IDocs corresponding to the incoming message are successfully created i.e. if the incoming file has 10 messages, then 10 IDocs have to be created, but committed only when all these 10 are successfully created.

I tried using the FM 'IDOC_INBOUND_SINGLE' by setting the error flag and do_commit parameter but it works only when there is an error in the header of the IDoc and cannot be created. It does not work in case the IDoc is created but with in an error status.

Can anyone please suggest what else are the possibilities ?

Thanks in advance,

Archana.

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

1 Answer

  • Best Answer
    avatar image
    Former Member
    Sep 03, 2008 at 08:38 AM

    Yes you can , say post idoc's collectively after say N number or post idoc's at the end of each day .

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hi,

      I finally managed to handle this situation using FM 'IDOC_INBOUND_SINGLE'. I realised there is a message statement after this FM, and if that is executed the rollback is not successful, hence just removed the message statement and it works as desired. Still in case anybody has any other suggestions please let me know. They are always welcome.

      Thank you all for your attention.