Loading XML files to PostgreSQL database using Talend

One Star

Loading XML files to PostgreSQL database using Talend

Hi
We had of XML files that we loaded into our database, but each file only has 1 row in the table, where as each file has several rows. I believe this is because it is only recording the first entry for a node, and not all of the remaining entries. In the code example below, you will see that for Invoice items, there is 2 items in the code, but Talend is only picking up the first item, before being loaded into the database. Is there a way that the other items in the node that belong to the same tag can be imported into the database?
Thanks,
Killian
-<InvoiceItems>
 -<Item>
  <Description>ABC</Description>
  <Type>X-Ray</Type>
  <AmountExVAT>35.00</AmountExVAT>
  <InvoiceNumber/>
  <Date>2007-04-15</Date>
 </Item>
 -<Item>
  <Description>XYZ</Description>
  <Type>Medication</Type>
  <AmountExVAT>65.00</AmountExVAT>
  <InvoiceNumber/>
  <Date>2007-04-15</Date>
 </Item>
</InvoiceItems>
Moderator

Re: Loading XML files to PostgreSQL database using Talend

Hi,
Could you please check a component TalendHelpCenter:tFileInputMSXML which reads and outputs multiple schema within an XML structured file?
Best regards
Sabrina
--
Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.

2019 GARNER MAGIC QUADRANT FOR DATA INTEGRATION TOOL

Talend named a Leader.

Get your copy

OPEN STUDIO FOR DATA INTEGRATION

Kickstart your first data integration and ETL projects.

Download now

What’s New for Talend Summer ’19

Watch the recorded webinar!

Watch Now

Best Practices for Using Context Variables with Talend – Part 4

Pick up some tips and tricks with Context Variables

Blog

How Media Organizations Achieved Success with Data Integration

Learn how media organizations have achieved success with Data Integration

Read

6 Ways to Start Utilizing Machine Learning with Amazon We Services and Talend

Look at6 ways to start utilizing Machine Learning with Amazon We Services and Talend

Blog