Comment on ORDER BY and language tags

TO: DAWG WG list
CC: the people commenting (feel free to correct my summary)

 From the comments list:

http://lists.w3.org/Archives/Public/public-rdf-dawg-comments/2007Feb/0005.html
   and thread

My summary:
--------
1/ Language tags - suggestion to add to the SPARQL language spec that there be 
a defined ordering on language tags.

2/ Query about extensibility
Do extensions to the operator table apply to ORDER BY?

3/ A request for a test case.
--------

Note that this is tied to the operator table in sec 11 and what happens with 
"<" for literals with a language tag.

My understanding (Eric - can you confirm?) is that "<" on two literals with 
language tags is undefined and leads to an error.  As it's an error, an 
implementation is free to add "<".

Is it then legal to add "<" on unlike language tags so ordering works out?

Hopefully, that's a "yes"

As we don't require SPARQL engines to handle language tags, we can't add them 
to the ORDER BY section without adding them into the operator table, then the 
'use "<"' rule catches them.

Stephane refers to ARQ but there I preferred to give a total orders results 
which is deterministic always but is implementation dependent - for language 
tags it treats language tags as some sort of value space, named by lowercased 
language tag.  If all else is equals, it's lexical order of same language tag 
i.e. "x"@EN < "x"@en.  Similar for unknown datatype URIs and blank nodes there 
are sorting rules to put everything into a fixed order (which may change, but 
is very unlikely to, if you re-read the graphs with FROM - that's blank nodes 
for you).


For the test case: I found:
http://www.w3.org/2001/sw/DataAccess/tests/data/OpenWorld/open-eq-07.rq
on
http://www.w3.org/2001/sw/DataAccess/tests/data/OpenWorld/data-2.ttl
which is close but not quite right

 Andy

Received on Friday, 23 February 2007 17:28:18 UTC