Re: [TTL] Differences between SPARQL and Turtle.

On 25/04/11 13:48, Peter Frederick Patel-Schneider wrote:
> From: Andy Seaborne<andy.seaborne@epimorphics.com>
> Subject: Re: [TTL] Differences between SPARQL and Turtle.
> Date: Sat, 23 Apr 2011 11:33:08 -0500
>
>> (resent with note of ISSUE-1 for trackbot)
>>
>> RDF-WG ISSUE-1
>> http://www.w3.org/2011/rdf-wg/track/issues/1
>
> [...]
>
>> And added a new one: Turtle and SPARQL treat \u escape processing
>> differently because they happen at different times in the parsing process.
>>
>> 	Andy
>
> Which one is "right"?
>
> peter

What do you want to evaluate it's "rightness" against?  Both specs are 
possible designs, they are just different.  The wikipage has examples.

I think the most important consideration is Turtle and SPARQL alignment.

Eric is arguing for a change to Turtle (and SPARQL?) to allow \u 
processing in prefixed names (with Turtle processing rules) so 
characters can be tunnelled through the syntax.  That isn't currently in 
the Turtle spec.

I haven't see the requirement for this (which might exist - I haven't 
seen it).  I'm concerned that this is allowing writing bad IRIs too easily.

History:

The SPARQL design changed during the 1.0 process (I can't remember why) 
but in 2005-11 [1] said:

"Only escape sequences for characters that would be legal at that point 
in the grammar may be given. "

for IRI references and prefixed names so tunnelling characters was not 
legal.

The SPARQL design changed to the current one in 2006-10 [2].

Turtle 2006-12-04 [3] does not allow escapes in prefixed names.  Turtle 
goes back further [4] and \u is only in strings (like N-triples), not URIs.

The version of 2004-01-18 [5] does not mention the issue.

	Andy

[1] http://www.w3.org/TR/2006/WD-rdf-sparql-query-20060220/

[2] http://www.w3.org/TR/2006/WD-rdf-sparql-query-20061004/#codepointEscape

[3] http://www.dajobe.org/2004/01/turtle/2006-12-04/

[4] http://www.dajobe.org/2003/11/ntriplesplus/

[5] http://www.dajobe.org/2004/01/turtle/2004-01-18

Received on Monday, 25 April 2011 14:08:53 UTC