- From: Alberto Reggiori <alberto@asemantics.com>
- Date: Wed, 2 Feb 2005 12:22:32 +0100
- To: RDF Data Access Working Group <public-rdf-dawg@w3.org>
hi all,
I have small question about an example I came up to test grouping
Given the following data:
<http://example.org/book/book1> <http://purl.org/dc/elements/1.1/title>
"SPARQL Tutorial" .
<http://example.org/book/book1> <http://example.org/ns#price>
"42"^^<http://www.w3.org/2001/XMLSchema#integer> .
<http://example.org/book/book2> <http://purl.org/dc/elements/1.1/title>
"The Semantic Web" .
<http://example.org/book/book2> <http://example.org/ns#price>
"23"^^<http://www.w3.org/2001/XMLSchema#integer> .
is the following query
PREFIX dc: <http://purl.org/dc/elements/1.1/>
PREFIX ns: <http://example.org/ns#>
SELECT ?title ?price
WHERE
{
( ?x dc:title ?title )
( ?x ns:price ?price )
}
AND ( ( ?price < 30 ) || ( ?price > 40 ) )
going to fail accordingly to what stated in
http://www.w3.org/2001/sw/DataAccess/rq23/#CombiningPatterns
?
I think so - due the above query has two graph-patterns, and that the
constraints by definition do not bind any var - it should fail
While the following query would succeed
PREFIX dc: <http://purl.org/dc/elements/1.1/>
PREFIX ns: <http://example.org/ns#>
SELECT ?title ?price
WHERE
( ?x ns:price ?price )
{
( ?x dc:title ?title )
}
AND ( ( ?price < 30 ) || ( ?price > 40 ) )
due that the first (top most) graph-pattern binds ?x and ?price
accordingly
In other words, in the implementation, while processing the blocks
stack one should execute any "binding graph-pattern" first or fail if
not possible.
is this the correct behavior?
thanks
Alberto
-
Alberto Reggiori, @Semantics S.R.L.
www.asemantics.com
Received on Wednesday, 2 February 2005 11:22:38 UTC