on 10-06-2010 9:35 AM
HI Friends,
In my source structure i have field called "Purchase ID". I need to map this field to target based on one criteria as follows :
Only the following Purchase ID's should be considered from source xml.
Purchase ID
100
101
102
103
104
I should not pick any other values. If i get any other values. we should throw expection.
Kindly guide me friends.
Renu
Use function "FixValues" for this.
Add all values to the function, click on "throw exception"
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi ,
I used Fixed Values. I added all the values under 'value column' and chose 'throw expection' option
What i have to use under Key column ?
When i places some dummy texts under key column and tried to test in Test tab. I got the following error
Exception:[java.lang.IllegalArgumentException: No value found for '101'] in class com.sap.aii.mappingtool.flib7.TextFunctions method fixed_values[101, FixedValues{ purchase1=101}, com.sap.aii.ib.bom.flib.types.ValueMappingStrategy@1f5c37b, , com.sap.aii.mappingtool.tf7.rt.Context@6a12bdc] com.sap.aii.utilxi.misc.api.BaseRuntimeException: Exception:[java.lang.IllegalArgumentException: No value found for '101'] in class com.sap.aii.mappingtool.flib7.TextFunctions method fixed_values[101, FixedValues{purchase1=101}, com.sap.aii.ib.bom.flib.types.ValueMappingStrategy@1f5c37b, , com.sap.aii.mappingtool.tf7.rt.Context@6a12bdc]
kindly guide me
Hi,
it is very simple, write simple UDF to check the value is in list or not, if it is not thorw java execption,that means your mapping will be failed,
are you sure that you want throw execption??
Regards,
raj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
92 | |
11 | |
10 | |
9 | |
9 | |
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.