Re: ASCII Control/Unicode C0 chars in SPARQL result format

On Aug 20, 2012, at 12:49 PM, Steve Harris wrote:

> How do other implementations represent the C0 control chars in SPARQL XML result format?
> 
> They're not legal in XML 1.0 (http://en.wikipedia.org/wiki/Valid_characters_in_XML#XML_1.0), and it seems that many XML libraries choke on XML 1.1 data.
> 
> This is a bit unfortunate if you have C0 chars in your literals.
> 
> Things we've considered:
> 
> * try to conneg XML 1.1 so at least our clients can take it (doesn't appear to be easy/obvious how, and some things are not even legal in XML 1.1)
> * replace C0 chars with something else from unicode, and return a 203 status, or something similar
> * give an error
> 
> None of these is terribly satisfactory though.

I'm sure my system breaks on control chars, but my initial thought after reading your email was to use the replacement character (U+FFFD) in place of the control chars. I agree it's not terribly satisfying, though.

.greg

Received on Monday, 20 August 2012 17:04:22 UTC