Nested XML file load

Hi Team

I am trying to load nested xml in Neo4j DB but unable to figure out how to fetch nested elements from xml files. In below xml file i would like extract both contact information. How can i use parse to those element using apoc.load.xml ?

<catalog>
   <book id="bk102">
      <author>Ralls, Kim</author>
      <title>Midnight Rain</title>
      <genres>Fantasy</genres>
      <price>5.95</price>
      <publish_date>2000-12-16</publish_date>
	  <contact>
         <email>123@gmail.com</email>
         <telephone>999999999999</telephone>
	  </contact>
      <description>A former architect battles corporate zombies,
      an evil sorceress, and her own childhood to become queen
      of the world.</description>
   </book>
</catalog>

Hi Mr dino
You need to write a custom contact info extractor program in languages supported by Neo4j,add them in APOC plugin libraries and then call them in cypher query language or any other program and bring it in Neo4j for further data modelling exercise.
Thanks

1 Like

Thanks for response Sameer.
Does it mean that Neo4j doesn't have in-built support for parsing Nested elements of XM ?

1 Like

It does have one more function apoc.xml.parse. It returns a map of values which you can use
to construct a Entity Relationship Model Catalog{Book{Contact}}.

1 Like