Link to home
Start Free TrialLog in
Avatar of p1800volvo
p1800volvo

asked on

Special Characters in XML to avoid?

Are there any characters that should be avoided (besides the  < > & " '). I am trying to process data that has sections that start with a backslash "\" and contain multiple dollar signs "$". This data is failing the import. $MM56A:$F603 is some of the data.

Thanks!
Avatar of Gertone (Geert Bormans)
Gertone (Geert Bormans)
Flag of Belgium image

in PCDATA only <> and & should be escaped.
All the other data needs to be conforming the encoding
so having a single byte encode 'é' in a UTF-8 is not allowed

some binary characters are not allowed as welll: NUL, BELL, ....
if you are pushing binary data in your XML, you would better check the XML specification
http://www.xml.com/axml/testaxml.htm
for allowed characters
Avatar of p1800volvo
p1800volvo

ASKER

The data is wrapped in CDATA. The $MM56A:$F603 section is actual text, not binary. Just need to ensure that it is not being misinterprited as another character set. We are importing under XML 1.0 but the database is not UNICODE, single byte characters only.

Thanks!
ASKER CERTIFIED SOLUTION
Avatar of Gertone (Geert Bormans)
Gertone (Geert Bormans)
Flag of Belgium image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial