Click here to Skip to main content
15,881,173 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi Friends,

I have an SSIS Package which reads XML file using XML Source Component.
This XML File has two outputs. One is for "Invoice" and other is for "InvoiceDetail"
The structure of the XML File is like this.

XML
<my:myFields>
<my:group1>
        <my:Invoice>
            <my:field1>1</my:field1>
            <my:field2>2014-11-11</my:field2>
            <my:field3>33370</my:field3>
            <my:Group2>
                <my:InvoiceDetail>

                    <my:Sub6 xsi:nil="true">100</my:Sub6>
                    <my:Sub7 xsi:nil="true">Charges</my:Sub7>
                    <my:Sub8>140</my:Sub8>
                    <my:Sub9 xsi:nil="true">78</my:Sub9>
                    <my:Sub10 xsi:nil="true">0</my:Sub10>
                    <my:Sub12>0</my:Sub12>
                </my:InvoiceDetail>
            </my:Group2>
            <my:field18></my:field18>
        </my:Invoice>
</my:group1>
</my:myFields>



I can get all fields of Invoice and InvoiceDetail in seperate outputs. But, I cannot join these rows since InvoiceDetail doesn't have the ID (field1) which links to the Invoice. Is there any idea to get the InvoiceID field also with the InvoiceDetail output ?

(Please don't ask me to add an ID in sub-rows too.. This file comes from another retailer using InfoPath.)

Thanks
Posted
Updated 6-Jan-15 21:12pm
v2

1 solution

try this Link
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900