Q: ADO.NET Reading XMLTypes > 4000 chars

G

gm0ney

I can't seem to find anything on this subject.

I find examples, but they do not work when the return value
for the column is over 4000 chars.


I know the underlying type for the XMLType is a CLOB, but
I can't seemed to find a way to get this value out of the DB
with ADO.NET using either the MS provider for the ODP.NET
provider.

Anyone got a sample or example?



Thanks,
g
 
G

gm0ney

Anyone got a sample or example?

Never mind... I figured it out right after I posted this... doh!
Stupid 2 lines of code.... bah

Its basically this if anyone else needs help with this.
This is done with the ODP.NET from Oracle

--- snippet ---

Dim dr as OracleDataReader = cmd.ExecuteReader
Dim oraXMLType as OracleXmlType

While dr.Read
oraXMLType = dr.GetOracleXmlType(0)
End While

Dim oXML as Xml.XmlDocument = oraXMLType.GetXmlDocument

--- snippet ---



g
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top