on 03-19-2014 11:06 AM
Hi All,
We have IDoc to File(CSV) Scenario.
Target Field Values have comma(,) character in it. Field Separator : comma(,)
Fields contain comma disturbs the File Generation Sequence.
eg.,
Header
field 1, field 2, field 3, field 4
field 1=test
field 2=sample
field 3=firstname,lastname
field4 = address
Output CSV:
field1, field2 , field 3, field 4
test,sample,firstname,lastname,address
Field 3 Value has been splitted into two. How to handle this case. Kindly help
Best Regards,
Suresh S
Hello Suresh
A CSV field containing a comma should be enclosed in double quotes. Can you add quotes to the output?
Kind regards
Steve
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Double Quotes inclusion at Mapping level and following FCC Parameters helped to resolved that issue.
However, we just need to exclude again the double quotes in the field before posting it to end Application which can be handled through FTP Module level configuration.
Does anyone have idea about Standard Adapter Module which handle my requirement
Best Regards,
Suresh S
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Suresh
If the target application can't cope with the quotes, how does it require the output to be formatted when there is a comma in the data?
I found a similar discussion where Stefan Grube says it isn't possible to use commas in data and as a field separator.
http://scn.sap.com/thread/1810628
Kind regards
Steve
Hi Suresh,
Here is the simple udf to remove or replace at comma in the third filed.
public String ReplComma(String var1, Container container) throws StreamTransformationException{
return var1 = var1.replaceAll(",", " ");
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Suresh,
If you do not want comma in third field try to remove at mapping level and pass it target.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
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.