on 01-27-2014 3:06 AM
Hi,
I need the field names to be populated in csv file in header along with another header.
Material group
MaterialNumber, Name
12345, Test
i have used the below in fcc in receiver file adapter.
Transaction.fieldSeparator | 'nl' |
DETAIL.addHeaderLine | 2 |
DETAIL.headerLine Material
DETAIL.fieldSeparator | , |
DETAIL.endSeparator | 'nl' |
DETAIL.fieldNames | MaterialNumber,Name |
When I tried to give addHeaderLine as 1 to see only the field names in csv, it is also not working. Cache content is upto date.
Mapping is simply one to one.
Please let me know if anything missing.
1. AF_Modules/StrictXml2PlainBean - Add this is module Name
2. xml2plain - Module key
3. Local Enterprise Bean
Parameter
addHeaderLine - fromConfiguration
headerLine - (give whatever you want to see in HeaderLine)
This is for receiver file adapter.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks Amt. It worked. I am facing another issue like in name values are coming as test1,test2 for one material and in target csv file these two are showing in two different columns.
But client needs it in one column (test1,test2) and number in other column.
I used trim but it is not working.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks Amit. I can see the header field names now.
But I need two header lines like :
Material Group
Material , Name
12345, test
I gave aadHeaderLine as 2 and headerLine as Material Group , but now it is only showing Material Group not field names.
I tried to give 3 but it is giving blank space but not field names. For 4 also no result.
Can you please tell how to get both.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello,
>>But I need two header lines like :
I am not sure using FCC we can do this, but there is a workaround.
In mapping, use duplicate subtree option on "Details" node and then map fields present under first instance of "Detail" node with constant values like:
Constant(Material) ----GroupIndentifier
Constant(Name)------Name
and then do normal mapping for the second instance of "Detail" node .
and eventually use below FCC:
Detail.aadHeaderLine ------ 3
Detail.headerLine ----------- Material group
Detail.fieldSeparator---------- ,
Detail.endSeparator---------- 'nl'
Thanks
Amit Srivastava
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Swapna -
DETAIL.addHeaderLine | 2 |
DETAIL.headerLine Material
As you can see below, you can mention(to store header line) .headerLine when addHeaderLine is set to 3. May be try setting it to 3.
Converting File Content in the Receiver Adapter (SAP Library - Partner Connectivity Kit)
NameA.addHeaderLine
Specify whether the text file will have a header line with column names. The following values are permitted:
However can you share the screenshot of your receiver structure and sample output file. Could not understand the requirement.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.