on 02-17-2010 8:41 AM
Hi,
I have created an RFC lookup which retrieves the content of a table in the SAP ERP backend. The RFC returns a table of conversion values. I would like to save thise key/values so I can use the keys to convert the to the values, in later mapping steps.
The RFC works and I get a list of all the values that I need for my translation.
I have created a screenshot of the queues and the Java user defined function.
[Screenshot|http://screencast.com/t/ZTI5NTVjMDU]
It is weird that the Java function only can see the first line in the key array, when there is suppose to be many. Have anybody experienced this and know how to solve the problem.
It just seems to be a problem when I had the RFC function.
I'm using PI 7.11.
Although this thread is marked as answered, I thought it was appropriate to add an improvement on the solution that was mentioned in the thread.
Colleagues of mine hit this same problem. They solved it by processing the output of the RFC call, before passing it into the UDF which was intended to cache the data.
To accomplish this, they created a separate "fixing" UDF which was placed between the RFC and caching UDF. The sole action of this "fixing" is to read in a queue and write it directly out to the ResultList.
For whatever reason, this has the effect of presenting a queue to the caching UDF which the UDF is able to successfully process.
public void fixList(String[] input, ResultList result, Container container) throws StreamTransformationException {
for (int i = 0; i < input.length; i++) {
result.addValue(input<i>);
}
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Daniel,
Maybe it has sthg to do with the scope of the UDF ? What did you choose (queue ? context ? etc) ?
Rgds
Chris
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
strange ! Have you tried using PI built-in value mapping features ... I know it is possible to retrieve values from a backend, but it may require more effort to implement it !
According to your screenshot, UDF seems only to take 1st and last occurence of the input key/value pairs !
Chris
Edited by: Christophe PFERTZEL on Feb 17, 2010 11:19 AM
I'm using the build in RFC lookup functions of the PI system, and that is when my queues turn wierd.
I have now converted to a name value string from the RFC. Not the ideal solution, but it seems to work.
Daniel Graversen
[Figaf|http://piarchitecture.com]
Edited by: Daniel Graversen on Feb 17, 2010 12:17 PM
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.