cancel
Showing results for 
Search instead for 
Did you mean: 

Proxy to File scenario, dynamic target directory

Former Member
0 Kudos

Hi,

I have a proxy to file scenario which is a pass-through in which the output file is .csv.

And the selection of  target directory is depends on a particular filed value in the input xml.

Example for Condition :

If field1 = {a, b , c } the the output file should be in folder1 otherwise folder2.

I am confused whether to go for JavaMapping or UDF or with ASMA

Thanks,

Gowtham Bhogi

Accepted Solutions (0)

Answers (2)

Answers (2)

manoj_khavatkopp
Active Contributor
0 Kudos

Gowtham,

So i ve understood your requirement..you have created a structure for proxy with few fields say f1,f2,f3

and you are using f1 field to identify the folder which can be done with xpath condition editor as mentioned by Inaki , but this f1 filed should not be present in CSV file ...is my understanding right ?

if so then to remove the f1 field before you convert it to CSV using MTB you can try using remove payloadvaluebean  and then convert the xml fields f2 and f3 to CSV.

You can check RemovePayloadValuebean here :

but i wonder if the remove payload value bean removes the filed for multiple occurrence or not.

Br,

Manoj

Former Member
0 Kudos

Hi Manoj,

It is a pass-through scenario. All the fields should be available in .csv file.

Moreover, my problem is solved. I made a UDF making dynamic configuration for the folder selection using the below link on which the folder selection is dependent:

Dynamic file name for pass-through scenario - Process Integration - SCN Wiki

.

Thanks,

Gowtham

iaki_vila
Active Contributor
0 Kudos

Hi Gowtham,

If you are in a pass-through scenario i understand with this that you don't have ESR development therefore you can't use java mapping, UDF or ASMA. AFAIK you can use variable substitution

Another option is to deploy the bean developed by Eng Swee Yeoh

Regards.

Former Member
0 Kudos

Hi Inaki,

There is no ESR development but the selection of target directory depends data in the input xml.

Thanks,

Gowtham.

iaki_vila
Active Contributor
0 Kudos

Hi Gowtham,

Check variable substitution blog that a i mentioned before and ask about it if you have any doubt

Regards.

Former Member
0 Kudos

Hi Inaki,

I checked the blog already but my requirement is no need to pass the input xml field value into either the filename or the directory.

Input xml value is only for the selection of target directory

Thanks,

Gowtham

iaki_vila
Active Contributor
0 Kudos

Hi Gowtham,

My bad you explained it perfectly. You culd use the condition editor xpath option to determine the receiver if you would have a XML Xpath Condition in Receiver Determination - Process Integration - SCN Wiki

However you have a csv file, therefore you can't navigate in it, then if you want to maintain no ESR development you have two options:

1. Do a OS script

2. Do an own module java bean to change the path dynamically, in this solution you have the module developed by Eng.

Regards.