on 06-04-2010 11:56 AM
Hi Experts,
I have developed a file to file scenario. PI picks up a .csv file from an FTP server and delivers this file to another FTP server without any conversions. It's a simple passthrough mapping.
I wish to implement a validation to check the content of a particular field in the file. I have used no mapping in this case and cannot write any UDF for this. Please let me know how can I implement validation in this scenario?
Thanks,
Dhawal
Using adapter modules for validation is not recommended. SAP given mapping feature to validate and transform the message.
If you want to validate simply for deciding receiver, use conditional receiver determination and conditional interface determination.
thanks,
madhu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Madhu,
Thanks for the very helpful answer. However the content that will be used in conditional receiver determination would be a date field. Can I use variable value in the condition. For example, if the date is tomorrow's date then receiver 'A' else receiver 'B'. Is that feasible?
Thanks,
Dhawal.
why dont you try the design of using a flag and then handle your message flow?
/people/shabarish.vijayakumar/blog/2005/08/03/xpath-to-show-the-path-multiple-receivers
else use the option of enhanced RD - http://help.sap.com/saphelp_nw04/helpdata/EN/43/a5f2066340332de10000000a11466f/frameset.htm
this is what you can do;
1. Code a module that will do the required validation.
2. in the output message put all the incoming file data into one node called DATA and in another node called FLAG set Y or N
3. in the receiver determination check for Y or N in the flag field
4. have a simple java mapping that will extract the file data from the data node and set it to the output stream
Hi,
>>The problem here is that the message is not going through the mapping.It's File-PI-File scenario where PI reads the files from source FTP using File Content Conversion and transfers this file to target FTP.
The best thing is do one to one mapping and bring the input field value then based on that do conditional routing
Regards
> Can I use variable value in the condition. For example, if the date is tomorrow's date then receiver 'A' else receiver 'B'. Is that feasible?
You can use an enhanced receiver determination with a Java mapping.
The Java mapping parses the input file and determines th receive based on the condition you mentioned.
This Java mapping has to provide on XML structure as output corresponding to the receiver determination structure.
The target file structure will not be influenced by this.
Hi Dhaval,
If you want to check the structure then in the PI 7.1 XML validation is there, In sender agreement Integration Engine Validation and Adapter Engine validation are there, so we have to use those things.
Check
http://www.riyaz.net/blog/pi-71-xml-validation-in-integration-engine/
But if it is not related to the structure (if you want to compare the data of input file) then you have to write the custom adapter module.
Regards
Ramesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Plz refer below links for custom module development:
Where to get the libraries for XI development
http://wiki.sdn.sap.com/wiki/display/XI/Where%20to%20get%20the%20libraries%20for%20XI%20development
Adapter module development:
Thanks
Amit
write a custom module and attach it to the sender file adapter
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
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.