Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I have xml with the below format:
-<Document>
-<cltinf>
+<grphdr> (having many children)
+<pmtinf> (having many children and can be repeated with its children )
I want to extract them as columns which I am able to do that but the I want for each pmtinf occurrence to extract it as a new row, how to achieve this?
Hello
Can you show an example to explain your requirement? what you are getting now? what are your expected output?
Regards
Shong
Yeah sure, let assume the below schema:
<grphdr>
<ch1>
<ch2>
<subch2>
.......
</grohdr>
<pmtinf>
<pch1>
<pch2>
<pch3>
<subpch3>
.......
</pmtinf>
<pmtinf> (another occurrence of pmtinf; might be more than 2 occurrences)
<pch1>
<pch2>
<pch3>
<subpch3>
.......
</pmtinf>
I want the excel columns/row as follows:
Columns: grphdr, ch1, ch2, subch2, pmtinf, pch1, pch2, pch3, subpch3.
Rows: 2 rows, 1st row has values of grphdr and 1st pmtinf occurrence with its children. 2nd row has the values of grphdr and 2nd pmtinf occurrence with its children.
Hope this clarifies!
mentioned below is my example.
@mohamad taha, the tFileInputXML and tExtractXMLFields component don't support extracting data from different loop elements at a time. As a workaround, use different tExtractXMLFields components to extract data from each loop element, then merge all columns from the two outputs, please refer to this topic.
Regards
Shong