on 10-05-2012 8:48 AM
Hi Friends,
I want to generate a file using file receiver with the following requirement.
AXD43213456
field1,field2,field3,field4,field5
1001,John,Franscisco,mining,55
A002,Frad,Franscisco,mining,53
8001,James,Franscisco,mining,1005
4001,Predi,Franscisco,mining,505
A001,,Franscisco,mining,155
Where header - comes only once without field name.
Items - comes with field names
Currently am getting the values with out field names for items, I tried even with this parameter
row.processFieldNames = fromConfiguration but does not work.
I would def appreciate your help
Thx
Swana.
Hi Swana,
the header is easy, parameter addHeaderLine
The field name is more challenging, i think you need to solve it in mapping. The standard xml type looks like
<root>
<nameA>
<value1>value</value1>
<value2>value</value2>
<value3>value</value3>
</nameA>
<nameB>
<value4>value</value4>
</nameB>
...
</root>
You need to map it like:
<root>
<row>
<new>nameA</new>
<value1>value</value1>
<value2>value</value2>
<value3>value</value3>
</row>
<row>
<new>nameB</new>
<value4>value</value4>
</row>
...
</root>
I think that i most easy with xsl. You can get the elements name into its value for example with x-path function local-name().
Regards,
Udo
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
81 | |
10 | |
10 | |
9 | |
7 | |
6 | |
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.