Skip to main content

Why APPINOUS team?

How to dynamically change the receiver side folderpath and filename using UDF ?

UDF CODE :
       
Following code for changing the folderPath of target directory :

DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION); 
 
DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","Directory"); 
 
conf.put(key,folderPath); 

Note : Please mention 'ContextObject.Directory' in source Directory in communication channel.


Following code for changing the filename of target file :

DynamicConfiguration conf1 = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION); 
 
DynamicConfigurationKey key1 = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File", "FileName"); 
 
conf1.put(key1,fileName); 

Comments

Popular posts from this blog

PI/PO REST Adapter

Hi Guys, Do you look for a way of integrating your SAP PI landscape with other REST services or to publish a REST service yourself using an SAP PI Endpoint? If yes, then this blog could be of interest for you. Do you have already had a look at the SAP PI REST Adapter and its configuration and now you feel “a bit overwhelmed” by the amount of settings? If yes, then this blog is also the right one for you. We have prepared a collection of blog entries for the REST Adapter that shows architectural concepts and configuration of the SAP PI REST Adapter and explain the internal processing steps. We also added some sample scenarios to make it easier for you to understand how your scenario can be implemented using the PI REST Adapter. Let’s get started. The first Blog in this series is about the REST Adapter concept and its configuration capabilities. It is a good ramp-up start for working with the REST adapter. It is called PI Rest Adapter – Don’t be afraid The...

Why APPINOUS team?

I have some visions on mind. I think this is the team to make those visions happen. As part of my plan I have planned to develop our self technically and we needs to put our best efforts towards our visions. I spoke with many people regarding these visions. Everyone said " it won’t work. It won’t happen. It is impossible. " It's not about possible to do or not. It’s all about how far we tried. At least we should try and then we have to say this is not possible. Without a try just having a vision won’t work out at all. We guys are having the same thoughts and vision if I’m not wrong. We guys needs to think differently and work together to make our vision as a product. Everyone will say " you guys are thinking crazily. It will never work out ”. Just ignore them.  They are the people who will have fantastic dreams at night times and when they are waking up at the morning they will forget everything and will go to same office again. Don't draw a circle and restri...

PO useful links

SAP PI Learning Link PI node Function: http://saptechnical.com/Tutorials/XI/NodeFunctions/Page1.htm Format by example(in depth) http://saprainbow.com/sap-pi-mapping/collapsecontext-and-formatbyexample-to-convert-flat-structure-to-tree-structure/ Use One As Many (In depth) https://wiki.scn.sap.com/wiki/display/XI/Explain+node+functions   http://saprainbow.com/sap-pi-mapping/useoneasmany-explained-in-easy-exampl/ Netweaver BPM http://scn.sap.com/docs/DOC-28803 http://scn.sap.com/docs/DOC-60042 - BPM Example File content Conversion (FCC) http://saptechnical.com/Tutorials/XI/Contentconversion/page1.htm http://help.sap.com/saphelp_srm40/helpdata/en/2c/181077dd7d6b4ea6a8029b20bf7e55/content.htm Html to CSV using java mapping http://scn.sap.com/community/pi-and-soa-middleware/blog/2016/02/28/conversion-of-html-wrapped-excel-file-into-csv-file-using-java-mapping-in-sap-pi-731 Cus...