Re: Problem with CDATA section in FOR XML EXPLICIT



prashant.k.jain@xxxxxxxxx wrote:
Hi,
I am trying to create a XML out of sql 2005 database using FOR XML. I
need to create XML for tables which may contain data having
non-printable ascii characters (1-32 ascii character).
[...]
But i need to store this XML data in some sql XML variable as i need to
pass it to store procedure which expects an xml input. While doing
following i gets an error saying "illegal xml character"

Using CDATA sections only protects the content against being parsed for markup. It still has to conform to the XML rules on characters, so control characters are still illegal: you'll have to filter them out or encode them in some way.

///Peter
--
XML FAQ: http://xml.silmaril.ie/
.



Relevant Pages

  • Re: Special Characters not resolving
    ... starting data at the origin in an ORacle database is 2000 characters. ... When the XML isdelivered to me on disk and I load an ... Obviously I need to find either a way to have the XML file provider strip ...
    (microsoft.public.dotnet.xml)
  • Re: Special Characters not resolving
    ... various characters are resolved. ... Here is an example cut from 2 .XML files. ... write to disk to resolve the characters then load again. ... I have an XML file that is generated by Oracle. ...
    (microsoft.public.dotnet.xml)
  • Re: Serving RSS feeds
    ... so you need to handle some non-ASCII characters. ... You can't do this with the XML prolog, because the web server HTTP ... addtype application/rss+xml rss ...
    (uk.net.web.authoring)
  • Re: Converting "’" to an Apostrophe?
    ... euro symbol, double quote, etc.) to their ASCII equivalents? ... Maria's problem is expressed a bit vaguely but let's assume that her XML ... struggle to think up or locate ASCII equivalents for some of these. ... UTF-8 characters properly? ...
    (comp.lang.perl.misc)
  • Re: XML Manifest contains invalid characters
    ... characters in place of the ones in the path, ... The ImageStripper is writing the XML log file as if it were a an ordinary file ... is usually written in one or another form of Unicode, defaulting to UTF-8. ...
    (comp.lang.smalltalk.dolphin)

Loading