EDN Admin
Well-known member
My task is to insert an element into an existing XML document in an Oracle Database. I am using C# to interface with the DB. Since I am using Oracle 10g, I have limited ability to insert into specific positions in the XML document.
My approach is to try to load the XSD into an object in C# then retrieve the ordered list of elements for the node I will insert another element into. Unfortunately, the XSD uses <sequence>, so I cannot insert an element at the bottom on the
node. Is there an C# object that will let me load in a parent XSD and its children XSD (these are the complex nodes that I need to insert elements into) and will give me the list of elements for a specific xPath in the proper sequence? With the
ordered list of elements, I can use the Oracle insertXMLbefore function to enure the proper placement of the inserted element. I have tried
System.Xml.Schema.XmlSchema schemaXml = System.Xml.Schema.Read(tr, null);
but this does not appear to load a list of the elements.
Any help is appreciated.
Talmadge
View the full article
My approach is to try to load the XSD into an object in C# then retrieve the ordered list of elements for the node I will insert another element into. Unfortunately, the XSD uses <sequence>, so I cannot insert an element at the bottom on the
node. Is there an C# object that will let me load in a parent XSD and its children XSD (these are the complex nodes that I need to insert elements into) and will give me the list of elements for a specific xPath in the proper sequence? With the
ordered list of elements, I can use the Oracle insertXMLbefore function to enure the proper placement of the inserted element. I have tried
System.Xml.Schema.XmlSchema schemaXml = System.Xml.Schema.Read(tr, null);
but this does not appear to load a list of the elements.
Any help is appreciated.
Talmadge
View the full article