on 01-08-2007 6:19 AM
hi all,
I have a small doubt in mapping which i have shown below
<i>then</i>----->ZOILID
item--><i>exists</i>--><i>if </i> -
>ZOILID
<i>else</i>(5constants)
item is the node which has ZOILID as a subnode.If item exists then ZOILID will have a value which we enter(as shown in mapping).But if item does not exist i need to have 5constant values assigned to ZOILID....which i dont have any idea how to proceed with.
We can give one constant using the constant function but how to assign 5constant values.Do i need to write a UDF....as i dnt know java coding
Help will be greatly appreciated
thanks,
Nisheeta
Hi Nisheeta,
you could use 5 constants from ther constant functions and concat them. But with 5 constants you should use a UDF. Here a simple example.
String concatString = new String() ;
concatString = val1+ " " + val2+ " " +val3+ " " +val4+ " " +val5;
return concatString;
Hope this helps you.
Dominic
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Also Nisheeta read the article which enhances your mapping skills.
/people/sravya.talanki2/blog/2005/08/16/message-mapping-simplified--part-i
/people/sravya.talanki2/blog/2005/12/08/message-mapping-simplified-150-part-ii
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Is it that you need to create 5 different ZOILID nodes or assign all 5 values to one ZOILID node?
If you need to assign all 5 to one node: Simple. You can assign more that one value in the constant function that is available in the mapping editor.
If you need to create 5 different ZOILID nodes: You would need to write a UDF that will create these nodes.
This link will help you with the udf:
<a href="http://help.sap.com/saphelp_nw2004s/helpdata/en/b1/83a09f668320419dbe00a741e0fe6a/frameset.htm">http://help.sap.com/saphelp_nw2004s/helpdata/en/b1/83a09f668320419dbe00a741e0fe6a/frameset.htm</a>
Regards,
Smitha.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
<i>believe with constant standard function you can assign only one value at a time,</i>
Since you want all 5 values in one single node, all you need to do is to enter the values in the constant function with space as a delimiter.
Yes you can use it in the if-then-else function.
Regards,
Smitha.
Hi,
U can easily achieve this by graphical mapping, as
1) first check whether that field exists or not (If without else function)
2) if exists then (If function) check, whether that filed is null value
3)if it is null, in the then part take 5 constant functions and three concate functions, delimeter ','
That's it, u can achieve this, i jst tested and its working. I am jst fowardign the screen shot to ur mail id. If you want plz try this.
regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
24 | |
12 | |
9 | |
7 | |
6 | |
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.