cancel
Showing results for 
Search instead for 
Did you mean: 

Dynamic File names using File Adaptor

Former Member
0 Kudos

Hello PI Gurus,

I am working on IDOC to File scenario where IDOCs can be sales order or return orders, depending up on IDOC i need to produce a file on the same folder location with differnet names Suppose

If Sales order Idoc then Sales.txt

If Sales Order IDOC then Return.txt

Both has different mapping logic and different strctures, Is it possible to achieve using ONE communication channel?

THanks

Rajeev

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Rajeev,

If they both are having different structure, then the output files will not be the same. So they have different layouts. So you may need to use two communication channels for them and you may need to do like two different interfaces.

If they output files for both are same structure then you can have one communicaton channel. Then in that case what you do is write a udf where you will send the udf into a Filename and then you can use this as your filename in receiver communication cahnnel.

Regards,

---Satish

Former Member
0 Kudos

Hi,

you mean to say if the receiving file location is same for 4 interfaces with 4 different target structures in IDoc/any to File scenario there should be 4 Communicaiton Channel right? There is no other way around to have one CC instead of 4 by changing File name dynamically depending up on some mapping logic?

Thanks

Rajeev.

Former Member
0 Kudos

Rajeev,

If you want to use one idoc and create four files with each file structrue different then you have to use 4 communication channels.

If you want to use one idoc and create four files, each one having the same structure then you can use one communication channel and can give dynamic file names and dynamic directories.

Regards,

---Satish

Former Member
0 Kudos

Rajeev,

If your structures are different, then you have no other choice but to create two CCs.

If you having the same structure, then it can be handled by one CC.

regards,

Neetesh

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Rajeev

mapping logic and different strctures, Is it possible to achieve using ONE communication channel?

Well you need to create two channel because use differents structures.