Hello,
My interface is Proxy(xml)->PI->SFTP(EDIFACT).
I would like to use the sequential number generated by NRO to construct the filename(Ex; EDI_DELFOR_<NRO unique sequential Number>). So i have implemented dynamic configuration UDF in mapping along with required NRO module in receiver file channel but not able to get unique sequential number to filename, rather I am getting a constant value as $B2B_UEBNRTestNRO$B2B_END_UEBNR.
I am able to get a sequential number in file if i mapp this($B2B_UEBNRTestNRO$B2B_END_UEBNR) to one of the field in target structure.
Module:
FileName UDF:
public String FileName(String a, Container container) throws StreamTransformationException
{
try
{
DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION); DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File" , "FileName"); conf.put(key,a); return a;
}
catch (Exception e)
{
String exception = e.toString();
return exception;
} }