- From: Dan Connolly <connolly@w3.org>
- Date: Fri, 01 Apr 2005 13:05:52 -0600
- To: public-cwm-talk@w3.org
SPARQL editors drafts have gone back and forth between
using turtle/N3 syntax for patterns and using RDQL (s p o)
syntax. The WG adopted "turtle + variables" on 8 March.
Since then, in response to comments on the spec, the editors
have added shorthand syntax for reification:
[[[
<< ?s ?p ?o >> :saidBy "Bob" .
is short for the triple patterns:
_:b34 rdf:subject ?s .
_:b34 rdf:predicate ?p .
_:b34 rdf:object ?o .
_:b34 :saidBy "Bob" .
]]]
-- http://www.w3.org/2001/sw/DataAccess/rq23/#syntaxMisc
Revision: 1.290 2005/04/01 15:29:04
(and back to Revision 1.242 2005/03/14 )
This is the sort of reification that does *not* quote
the terms. i.e. we have
<< Mary hit [ a Ball ] >> rdf:subject [ a Person ].
not
<< Mary hit [ a Ball ] >> rdf:subject [ a Term ].
So it *does* follow from...
Lois believes << Superman a Hero >>.
Superman = ClarkKent.
that
Lois believes << ClarkKent a Hero >>.
The N3 {}s do quote terms, so it does *not* follow
from
Lois believes { Superman a Hero }.
Superman = ClarkKent.
that
Lois believes { ClarkKent a Hero }.
There's also the business of quoting multiple triples. The design
doesn't allow
SELECT ?who
WHERE ?who :said << ?anmial1 :eats ?animal2.
?animal2 :eats ?animal3 >>.
Hmm... how do []s inside <<>> work? I think
<< Mary hit [ a Ball ] >> a FunnyThingToSay
actually reduces to
<< Mary hit _:something >> a FunnyThingToSay
_:something a Ball.
I really wish RDF Core had deprecated rdfs:subject/predicate/object
because they don't get this quoting stuff right.
But they/we didn't. And DAWG has gotten comments from various
people that are using it and want syntactic support in SPARQL.
Maybe they/we should get some comments arguing against
this sort of reification syntax.
--
Dan Connolly, W3C http://www.w3.org/People/Connolly/
D3C2 887B 0F92 6005 C541 0875 0F91 96DE 6E52 C29E
Received on Friday, 1 April 2005 19:34:32 UTC