cancel
Showing results for 
Search instead for 
Did you mean: 

Dynamic ftp folder location

Former Member
0 Kudos

Hi ,

Is there any possibility that I can use the Dynamic configuration instead of variable substitution for changing the ftp folder location.....?

FLAG is a element in my document.

if FLAG = D route the file to below ftp path

/fmes/PM/S31/in/daily

if FLAG = M route the file to below ftp path

/fmes/PM/S31/in/month

Similliar to code as below, which is used for the FileName...

_______

Map map= container.getTransformationParameters();

//This is for generating the file Name Dynamically

DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);

DynamicConfigurationKey keyFileName = DynamicConfigurationKey.create( "http://sap.com/xi/XI/System/File", "FileDirectory");

conf.put(keyFileName, strFileName);

____________

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Follow this links it can helpful to you

/people/sameer.shadab/blog/2005/09/23/an-interesting-usage-of-variable-substitution-in-xi

/people/sravya.talanki2/blog/2005/08/11/solution-to-the-problem-encountered-using-variable-substitution-with-xi-sp12

/people/sap.user72/blog/2005/07/15/copy-a-file-with-same-filename-using-xi

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

Yes it should work. Instead of giving the keyword "FileName" use "Directory" in your code.

Then in communication channel use variable substitution as similar to below link,

http://help.sap.com/saphelp_nw04/helpdata/en/bc/bb79d6061007419a081e58cbeaaf28/content.htm

Pls Reward points if find useful

Thanks

Amit