on 12-12-2006 7:02 AM
Hi ,
I have a field of type string in my Source strucutre of type String which consists multiple values seperated by SPACE,
Now in mapping i have to segregate these values into individual fields could u tellme how is it possible,
Sample data:
========
Field: 200006 2000000018 2100000026548
these have to be mapped to a field "targetField" (0-unbounded) in target.
so my target would be
targetfield1 = 200006
targetfield2 = 2000000018
targetfield3 = 2100000026548
any inputs.....!!! any UDF i can use....? i am not good at java..though....!!!
Hi,
You can easily do this with a advanced UDF.
Follow this code:
give 'input' as the input parameter name.
String[] values = input[0].split(" ");
for(int k=0; k < values.length; k++)
{
result.addValue(values[k]);
}
Regards,
P.Venkat
Message was edited by:
Venkataramanan Parameswaran
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
80 | |
24 | |
12 | |
9 | |
7 | |
6 | |
5 | |
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.