on 04-19-2011 6:18 PM
Hi
I have a requirement. I have to use FCC at sender File adapter. In that there are around 20 odd fields. The first ten fields have comma as delimiter and the next are seperated by pipe.
How do I incorporate this requirement in the field separator ?
Regards
Radhika
Hi,
YOu can follow the folowing approach.
1) Proceed as if you have only Comma as separator.
2) This would result in the 11th field as a big string with all the data along with pipes as delimiters.
3) Then in the mapping for the 11th field, you can use a java udf to split at '|' and map the resulting 10 fields according to your requirement.
example
1stfield,2ndField,3rdField,.....,,10thfield!11thfield|12thfield|.....20thField
After havin FCC for only Comma, you would get a result as:
1stField
2ndField
3rdField
.
.
.
10thField
11thfield|12thfield|.....20thField
Then you can split the 11th field in your mapping.
Best Regards,
Ravi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If the first 10 fields and second 10 fields are under diff category, you can treat as different group and use something like Details_1 and Details2. If all need to be in one group then it is not possible to use different separator for the same group of fields. BTW, What is so special about last 10 fields to have diff separator. That tells me those comes under diff group.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
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.