Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Function to escape xml chars?
Hi,
I cannot find any function for XML as such. However, if you consult the section "Creating Non-Schema-Based XMLType Views" in chapter 11 "XMLType Views" of the "Oracle9i XML Database Developer's Guide - Oracle XML DB Release 2 (9.2) Part Number A96620-02", you will see an example of how to generate a XML document from an ordinary table via an XMLTYPE view and a SELECT statement.
The special XML characters of "&'<>" are all properly converted when the XML document is produced. That is, if a column contains the value "&'<>", then part of the result will show "<tag>&'<></tag>".
Douglas Hawthorne
"php newbie" <newtophp2000_at_yahoo.com> wrote in message
news:124f428e.0402011121.4bd44b4d_at_posting.google.com...
> For a website, I generate XML files dynamically from an Oracle
> database. After retrieveing the data, I need to put them in the XML
> file. But if the selected columns contain XML special characters,
> this doesn't work.
>
> Is there a function in Oracle that would escape XML/HTML special
> characters?
Received on Mon Feb 02 2004 - 02:03:46 CST