<Response>
<Items>
<attributes></attributes>
</Items>
<Locations>
<attributes></attributes>
</Locations>
</Response>
I have an XML file in the format shown above.
I want to save attributes
of parent Items
in a separate table in the database and attributes
of parent Locations
in another table.
I am not able to use XmlReader element .Read()
. I have been using XmlDocument.Load
to initially load the reader as XmlDocument
and by using
doc.SelectSingleNode("//Items")
will be selecting nodes
and will parse through the inside information through XmlReader
.
But now I am facing an issue in loading XmlReader
into an XmlDocument
as I get an OutOfMemoryException.
Can someone help me to solve this?