on 12-19-2014 9:39 AM
Hi
A file-to-file scenario where I've appended timestamp at the end of the filename. The task is now to append .dat at the end of timestamp.
If the file is Example
Then the target file should be as
"Exampleyyyymmddhhmmss.dat"
How can I accomplish this?
Please help.
Thanks in advance
DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
// Call the FileName parameter of Receiver File Adapter
DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","FileName");
String MyFileName ="Example".concat(var1).concat(".dat");
// Set the FileName dynamically to Receiver File adapter
if(conf != null)
conf.put(key, MyFileName);
return MyFileName;
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You use ASMA+ Dynamic Configuration. You may set the file name as required.
Thanks,
Sudhansu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Abinaya,
you do not need an UDF for this purpose.
Simply use "Example.dat" as filename pattern in the receiver communication channel and select the option "Add Time Stamp To File Name" as File Construction Mode.
The timestamp is always inserted before the last full stop in the pattern.
Best Regards,
lars
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
80 | |
24 | |
12 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.