on 10-30-2007 10:03 AM
I have as many as 30 interfaces which will have to use the same UDF. So I have to create a new UDF in each Interface.
My question is is there a way that we can place this UDF centraly something like a Function Module or a Subroutine and call it or use it where and when require. Because, if tomorrow, if any small change comes for in the UDF... It is very laborious work we need to do.
I want to control this at ID level rather than IR.
So that I can control before the mapping itself.
Any thoughts please...
Thanks
Kiran
its avilable in new version PI7.1
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can create a mapping template in a central SWVC. Here you define all UDFs that you need. Apply this template to all your mappings.
The only issue is: When you find a bug in an UDF, you have to fix this in all mappings, that use the UDF already.
But a combination of external classes and UDF in mapping template should help for 7.0.
Regards
Stefan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Kiran,
I am fine ...
An Idea for your post ---> <b>If your set of source & target values are fixed</b> then you can do as follow,
1. As per your requirement you can go for Value mapping . in your mapping by using value mapping function you can retrieve the corresponding values from source to target in all of u r sceanrios.
2. If you dont want to use the value mapping,Create a Z table and maintain the source and target values in that table.While population of Idoc( User exit of the transaction which is using for populating the Idoc) u need to do the validation and get the corresponding value for your source to target from the table and modify the Idoc field with the value from table.So that in all of u r mappings its just one to One mapping.
Hope it will helps to you..
Cheers
Veera.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello!
> My question is is there a way that we can place this UDF centraly something like a
> Function Module or a Subroutine and call it or use it where and when require.
The best approach is to put logic which is needed in several UDF in separate java classes as imported archives.
Within the UDF there would be no logic but you'd just call the logic in the imported archive classes using something like:
return MyClass.myMethod(parameter);
That way all the UDF share the same function and you need to make changes only in the class in the imported archive and not in all UDF.
Regards, Tanja
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
What you can do is write a Java code and import it into one common SWCV. Now this java code will be accessed from any of the software component version.
Now pass the value to this common java code from the interface and this common java code will return back the result to your interface.
For example:
1)First import the package inyour UDF which will be calling the common java code.
2) pass the value to the common java code.
For example:
public boolean file(String InterfaceID,String FileName)
file is the class which is written in common java program and the interfaceiD and fileName is the value which are passed to common java code.
I think this will resolve your problem.
Thanks and Regards,
Chirag Gohil.
Hi Kiran,
What is u r exact requirement, what is the common functionality for all 30 interfaces u want to fullfill by writing the UDF. Provide some more details on this for more ideas ..
Cheers
Veera
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hey veera,
How are you?
My requirement is: Actually an IDoc to File Scenario.
I already posted in my earleir post and however expalining the same again here....
I will have set of faulty numbers in Idoc and each number shall be identified and shall be replaced with another number and put them into FILE.
So I had a code for this in UDF and using it.
Till here, its working fine.
But this functionality is to be put into as many as 30 interfaces. Thus I am seeking for some clues to know if any coding can be handled centrally in ID area. MIND not in IR because, I saw ajays explanation to import .jar files. But this way, i am again creating UDF in each interface which I want to avoid.
Hope am clear in expressing.
Please let me know your thoughts.
Thanks
Kiran
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
It is possible from 7.1 but not 7.0 or before.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
89 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.