- From: Jeen Broekstra <j.broekstra@tue.nl>
- Date: Thu, 14 Jun 2007 10:59:28 +0200
- To: andy.seaborne@hp.com
- CC: RDF Data Access Working Group <public-rdf-dawg@w3.org>
Seaborne, Andy wrote: > Checked in: > > http://www.w3.org/2001/sw/DataAccess/tests/data-r2/algebra/ > > 12 tests. > > These tests cover various issues to do with the SPARQL algebra, such as > filter scopes, nested optionals, repeated optionals using the same > variable. > > There may well be duplication with tests elsewhere but it's probably > useful to have a set focused on algebra matters all in one place. > > This is not intended to be a complete coverage. If there are specific > other areas for the algebra that people would like covered, please say > so. Or supply additional tests! I'm having difficulties with the first test, Nested Optionals 1. Perhaps I'm out of touch with how the behaviour of nested optionals is defined, but: data: :x1 :p 1 . :x2 :p 2 . :x3 :q 3 . :x3 :q 4 . query: SELECT * { :x1 :p ?v . OPTIONAL { :x3 :q ?w . OPTIONAL { :x2 :p ?v } } } I would intuitively expect the result to be: ?v ?w 1 3 1 4 According to this test, however, the result is: ?v ?w 1 - I guess this has something to do with the pattern in the second optional not matching due to ?v being bound to value 1. However, given that this is an optional pattern I do not quite understand why it makes the _first_ optional clause fail as well. Jeen -- Dr. Jeen Broekstra Den Dolech 2 Information Systems Group HG 7.76 Department of Mathematics and Computer Science P.O. Box 513 Technische Universiteit Eindhoven 5600 MB Eindhoven tel. +31 (0)40 247 36 86 The Netherlands
Received on Thursday, 14 June 2007 09:02:59 UTC