on 12-22-2009 7:56 AM
Hi All
PI Version = 7.0
Scenario is:
Total number of Scenarios = 20
I have created UDF in one mapping for one scenario. Same UDF i have to use for all 20 scenarios. Do i need to go to each maaping and have to write UDF or can i create one UDF and can use same for all scenario. Is there any posibility like this in 7.0, if yes then how can i achieve this???
Regards
Dheeraj Kumar
Hi,
write it as a separate method in a class, import the class and use the function in each of ur scenarios.
Hope it helps
BR
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You can also create a mapping template and include your UDF in your template. When you create new mappings (for the 20 scenarios) you can base them on the mapping template and your UDF will be available for all. It doesn't matter if your template doesn't match your current source/target formats, you can still use the template and make use of the common UDF.
Hope it helps!
Br,
Kenneth
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I think it should be possible. Select a source node and target node in your mapping where your UDF is defined and click "Create mapping based template". Then in your other message mappings you can select "show suitable templates" and select the one you just created.
Let me know if it works!
-Kenneth
Hi Dheeraj,
If my understanding is correct mapping templates use data type and not message types.
So if the associated data type for your source and target nodes have the same data types associated to them, I think it should work.
However you can always go for other option of creating a class and importing it under Imported Archives.
Regards,
Sanjeev.
Hi Dheeraj,
As suggested by Abhishek earlier you would have to create a java class using NWDS and then import it in the IR under Imported Archive. This can then be referenced in your UDF.
For more on this have a look into these links:
http://help.sap.com/saphelp_nw04/helpdata/en/14/80243b4a66ae0ce10000000a11402f/frameset.htm
http://help.sap.com/saphelp_nw04/helpdata/en/14/80243b4a66ae0ce10000000a11402f/frameset.htm
http://help.sap.com/saphelp_nw04/helpdata/en/14/80243b4a66ae0ce10000000a11402f/frameset.htm
The way to reference the imported archives is explained here.
Regards,
Sanjeev.
You should still be able to use a template even if your structures are different to the template. The only consequence is that no fields will be mapped as a result of the template mapping, but the positive is that you will get all UDF's defined in the template available. There is however a restriction I think that you need to use data types or message types as part of your template, external definitions will not work.
-Kenneth
User | Count |
---|---|
101 | |
13 | |
13 | |
11 | |
11 | |
7 | |
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.