cancel
Showing results for 
Search instead for 
Did you mean: 

Duplicating an IDOC conditionally

Former Member
0 Kudos

Hi,

I am working on a scenario where in the requirement is to duplicate an IDOC conditionally.

The scenario:

<b>File <i>>(User Defined Java Function)</i>> IDOC</b>I receive a fixed length file from a Legacy system and I have to generate one IDOC for every record of the file received. Now, in order to populate the fileds of the IDOC, I have written a large java function to conditionally populate the IDOC fields.

In certain cases, say if Condition 'X' is satisfied, I have to generate 2 IDOC's instead of 1.

I hope the above explains my case.

BPM could have been an option, but I am looking at really huge volumes of data (more than 1,00,000) and hence I wanted to avoid BPM.

Any help on this will be appreciated.

Thanks,

Vijai

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Vijai , I doubt if you can do this without a BPM, but if you are worried about calling the transformation(message mapping) inside a BPM , you can definitely avoid it , but u still need a BPM to just route it to ur IDOC adapter.

export your idoc to the file system(Tools -> export XSD), change the "occurence" of the IDOC (add minOccurs = "0" maxOccurs = "unbounded" next to the IDOC node), now import it as an External definition(IDOC package).

Now you can map the incoming file to this IDOC package, call this mapping in the interface determination b/w your file sender & bpm receiver. Now in bpm just send this IDOC package out and receive it in your idoc adapter(will splt this idoc package into ind. idocs and sends it to sap)

-Saravana

Former Member
0 Kudos

Hi Saravana,

Thanks for your reply.

I have already taken care of the splitting part with out using BPM :o)) (basically whatever you have explained, but without BPM). My problem is more to do with the Conditional duplication.

In the mapping process, using a Java function I have a contional program and if some condition gets satisfied then at that point (for that particular record of the incoming file) I have to generate 2 IODC's instead of one.

I hope I am able to explain things to you.

thanks, Vijai

Answers (0)