on 04-09-2009 9:21 AM
Hi
We are doing a file to idoc scenario. The idoc has two fields which requires data from the next record to be filled in them.
Is there a standard way of doing it?
Regards
Sourabh
What is Next Record ? Give an example.
For quick ans try to be more spicific while explaining your problem.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Can I put data from two different recordsets to a single idoc, for example
In your Source file you have a field called "Status"
In your Target file you have fields called "Status" and "Status of Next Record"
Now the problem is how can I do the mapping for the "Status of Next Record" for which i have to pick data from the "Status" field of the next recordset and not the current one.
I think you can create a UDF 'nextStatus', which takes all values of a context in a variable 'status' and the following code:
for(int i = 0; i < status.length; i++){
if(i < status.length-1)
result.addValue(status[i+1]);
else
result.addValue("");
}
This will return the status of the next element. Insert this in your mapping as follows:
[STATUS] -> [UDF nextStatus] -> SplitByValue -> [NEXTSTATUS]
Make sure all values of the input 'STATUS' are in one context (use removeContext if required).
Kind regards,
Koen
Hi,
Please explain your scenario with an example. I could not get your problem.
Regards,
Shweta.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
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.