Skip to end of metadata
Go to start of metadata



XML Extract

Author: Jerry Chae

This plugin is based on lmxl (Python) technology https://lxml.de/. It extracts data from XML file and output in a CSV file.

Need help?

Technical contact to tech@argos-labs.com


May you search all operations,



NOTE

Please note when your XML file contains inconsistent number of data under specific TAG(s), the output CSV may not be in the intended format.

For detailed explanations of the libraries of this plugin please visit this website, https://lxml.de/xpathxslt.html




Example


1. Target XML file


<bookstore>


<book category="cooking">

  <title lang="en">Everyday Italian</title>

  <author>Giada De Laurentiis</author>

  <year>2005</year>

  <price>30.00</price>

</book>


<book category="children">

  <title lang="en">Harry Potter</title>

  <author>J K. Rowling</author>

  <year>2005</year>

  <price>29.99</price>

</book>


<book category="web">

  <title lang="en">XQuery Kick Start</title>

  <author>James McGovern</author>

  <year>2003</year>

  <price>49.99</price>

</book>


<book category="web">

  <title lang="en">Learning XML</title>

  <author>Erik T. Ray</author>

  <year>2003</year>

  <price>39.95</price>

</book>


</bookstore>




2. Input Xpath


/bookstore/book/title

/bookstore/book/author

/bookstore/book/year

/bookstore/book/price




3. Output CSV


title,author,year,price
Everyday Italian,Giada De Laurentiis,2005,30.00
Harry Potter,J K. Rowling,2005,29.99
XQuery Kick Start,James McGovern,2003,49.99
Learning XML,Erik T. Ray,2003,39.95





How to set your parameters.



Text from Image

Return Code

Code
Meaning
0Execution successful
1Execution failed



All Plugins