Note: This was originally posted by an inactive account. Content was preserved by moving under an admin account.
Originally posted by: xathrasHi,
I am looking at the XML Node, but wanted to ask some more question. I have some simple output, e.g. below:
type:string, trantype:string,bin:string,merch:string,profile:
EC, AC,000001,012012,1
EC, AC,000001,012012,2
EC, AC,000001,012012,3
EC, AC,000001,012012,4
and I want to convert it into an XML output like the below.
<?xml version="1.0" encoding="UTF-8"?>
<transRequest RequestCount="4" xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance">
<batchFileID>
<userID>bob</userID>
<fileDateTime>20110610191317</fileDateTime>
<fileID>batch_20110610191317</fileID>
</batchFileID>
<newOrder BatchRequestNo="1">
<type>EC</type>
<trantype>AC</trantype>
<bin>000001</bin>
<merch>012012</merch>
<profile>1</profile>
</newOrder>
<newOrder BatchRequestNo="2">
<type>EC</type>
<trantype>AC</trantype>
<bin>000001</bin>
<merch>012012</merch>
<profile>2</profile>
</newOrder>
<newOrder BatchRequestNo="3">
<type>EC</type>
<trantype>AC</trantype>
<bin>000001</bin>
<merch>012012</merch>
<profile>3</profile>
</newOrder>
<newOrder BatchRequestNo="4">
<type>EC</type>
<trantype>AC</trantype>
<bin>000001</bin>
<merch>012012</merch>
<profile>4</profile>
</newOrder>
</transRequest>
Is it possible to do this with current node, or do I have to massage the data? See example
Where RequestCount would = number of transactions and BatchRequestNo = request number (e.g. sequence).
Ideas would be greatly appreciated.
Regards
Wayne