cancel
Showing results for 
Search instead for 
Did you mean: 

Dynamic File name in File adapter

former_member189558
Contributor
0 Kudos

Hi All,

1)We need to construct dynamic file name. Just want to confirm it is supported in PI7 SP 11.

2) We are splitting the inputs to target fileS for <b>each order</b>. For this how to construct each file with a different order number in it? I am concerned that only the first order number will be taken and applied for all files.

Thanks,

Himadri

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Refer to blog

/people/michal.krawczyk2/blog/2005/11/10/xi-the-same-filename-from-a-sender-to-a-receiver-file-adapter--sp14

May be helpful for you

Regard

Sushil

Answers (1)

Answers (1)

justin_santhanam
Active Contributor
0 Kudos

Himadri,

Dynamic file name is supported in SP11.

See while doing Dynamic file name in UDF get the <b>order</b> as input, while writing file name use this order so each time if the order changes it will create differerent file with order name in it.

This is what u r looking for?

Best regards,

raj.

former_member189558
Contributor
0 Kudos

I am concerned, that my source will contain multiple orders.. the adapter will split to multiple files for each order,,, There I want to ensure that Each file gets it own corresponding order number as a name.

Is this posible?

Thanks and Regards,

Himadri

Former Member
0 Kudos

Yes it is psb..

You need to create a UDF for it & input to UDF must be ordar no (which will be going to target field i e. after spilling the source file). So as multiple files will be generated, each will contain only one value of order which you UDF (User Defined Function) will be using so files will be having correct name as expected.

Regards

Sushil

Former Member
0 Kudos

Himadri,

First read the file with all orders. Assuming you are going to write file for every order then for that particular file order name is not going to change. So use this order number in variable substitution and get the filename as order number.

---Satish

former_member189558
Contributor
0 Kudos

Many Thanks Satish ,

It worked )

Himadri