cancel
Showing results for 
Search instead for 
Did you mean: 

How to Add Column header in a CSV ?

Former Member
0 Kudos

Hi,

I am trying to develope a scenario to convert an XML file into CSV file, the scenario is populating values of all fields in the CSV file properly, but i am not getting the column header for any field in my CSV file.

Source xml structure : <item>

<name>

</name>

<roll>

</roll>

<age>

</age>

</item>

I have configured FCC in the receiver communication as follows :

Recordset Structure : item

item.addHeaderLine : 1

item.headerLine : name,roll,age

item.fieldseparator : ,

item.endseparator :

item.fieldnames : name,roll,age

Can anyone suggest , what should i add or modify in the scenario to get column header for all the fields in the CSV ??

Edited by: Sambaran Pradhan on Jun 19, 2008 10:43 AM

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Your FCC parameter item.headerLine : name,roll,age will work if the item.addHeaderLine == 3 or 4

Else for value 1 it will take the names from XML document.

For item.addHeaderLine

Specify whether the text file will have a header line with column names. The following values are permitted:

· 0 u2013 No header line

· 1 u2013 Header line with column names from the XML document

· 2 u2013 As for 1, followed by a blank line

· 3 u2013 Header line is stored as NameA.headerLine in the configuration and is applied

· 4 u2013 As for 3, followed by a blank line

Refer

http://help.sap.com/saphelp_nw04/helpdata/en/d2/bab440c97f3716e10000000a155106/frameset.htm

Answers (2)

Answers (2)

Former Member
0 Kudos

No, i am using a single structure, what i had mentioned earlier .

Former Member
0 Kudos

Hi,

Thanks for ur suggestion, but it is still not working, i have tried all the options.

Former Member
0 Kudos

Hi,

Do you this single structure on target side or multiple structures as

<Item1>

-


<A>

-


<B>

</Item1>

<Item2>

-


-


</Item2>

If this the caes then it will not be possible to use the addHeaderLine. It will not work.

Thanks

sWarup