cancel
Showing results for 
Search instead for 
Did you mean: 

creation of multiple files as per segment repeating multple times in IDOC

venkatasap
Participant
0 Kudos

Hi SapAll.

i have got a requirement where in an IDOC to File Interface pi need to create 3 different files with same content but with different names based on single Idoc-Segment.

its an IDOC to 3 File Inteface.

the file names will be determined by the IDOC-SEGMENT(Zregion)-Field (where Zregion Which will repeate for 3 times )

for achiving this

i just created 3 message (Service )Interfaces and one message mapping,3 Interface(Operation) mappings in the design and In the configuration i created three reciever communication channels with one reciever detarmination ,one Interface determination and 3 reciever agreements (with 3 communication channels 1 for each)

in the Interface Determination i just defined 3 operation mappings,3 reciever Service Interfaces with one condition each.

the condition is like below

(/ZARTMAS05/IDOC/Z1EDRMDFRH_REGION01/REGION = JNB) then Rec Interface1

(/ZARTMAS05/IDOC/Z1EDRMDFRH_REGION01/REGION = DBN) then Rec Interfacde2

(/ZARTMAS05/IDOC/Z1EDRMDFRH_REGION01/REGION = CPT) then Rec Interface 3 where (/ZARTMAS05 is the sender idoc.

but iam getting only one file in the reciever side instead of 3 files.

can any body help me in providing me the differnt solutions for this without use of any script executions.

will be waiitng for response.

regards.

Varma

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi

If you have condition based interfae determination, the message will be routed to only one interface mapping. I mean the input message will go to only one interface mapping which would create only one output file.

If your input message satisfies all 3 conditions, then only the message will go to 3 interface mapping ( 3 files).

venkatasap
Participant
0 Kudos

Hi Rajesh.

Thanks for your response.

yes iam getting 3 output files created if all the 3 conditions defined in Interface Determination has been satisfied but i have another requirement which is also in connection with this.

the requirement is if COND1 in Interface Determination is satisfied then pi should create file using COM1 communication channel

with file name taking from source IDOC IDOC Zsegment-Region(Fileld).

the same thing should happen even wiith the other 2 communication channels.

i mean if the IDOC has got 3 zregion segments then pi should create 3 files based on the condition specified but i am not getting the file names created in the desired way.

things i have done in message mapping -

taken the region field from zidoc-zsegment and mapped to dynamicConfSetFileName then mapped to target variale file name (created in the recievr data type in message mapping) ,in the config i have used (use adapter specific message attributes option in comm channel) .

your help would be appreciated.

regards.

Varma

Former Member
0 Kudos

what ever you designed if you want to create always three files then your approach is correct.

if you want create multiple files based on all the condition you you have to change the logic as like below.

your message mapping sould me - one source target message type -> three traget message type all are occurance is 0..1

and check the message type level contion if the region=ABCD create the first message type..

same thing in your interface determination one source interface -> target three interface occrance is 0..1

ID Steps - 1 RD, 1 ID, 3 Receiver coom channesl and 3 receiver aggreee...

after develope this scenario it will split different message types in SXMb_MONI under the Technical Routing...payload level.

hope it will help you to solve your requirement...

Regards,

Venu.

Former Member
0 Kudos

you say you have 3 different target messga interface, create 3 different message and interface mapping. In this case you have 3 scneario and hence 3 diff comm channel which is enough for the requirment

i think you are already doing this. Can you let us know where is the issue?

Answers (1)

Answers (1)

rajasekhar_reddy14
Active Contributor
0 Kudos

may the data what you have provided not matching your interface determination conditions.

that could be the reason

\

Regards,

Raj