Thursday, March 27, 2008

XMLType extract on XML with namespaces

Guess what, using extract('/mynode') in Oracle will not return mynode if the XML file has namespaces that Oracle doesn't recognize. The solution? use extract('/mynode','paste all your namespace declarations in here'). So for example:

extract('/mynode','xmlns="http://stupidideas.net/stupid" xmlns:dumb="http://dumb.com/dumber"')

See also:

http://pbarut.blogspot.com/2006/11/xmltype-and-namespace-problem.html

3 comments:

Anonymous said...

You saved my day..thank you..very much. Good Day

Anonymous said...

Wintown.

Anonymous said...

Breve y certero, una maravilla.
Thanks a lot.

Labels

Blog Archive

Contributors