W3C home > Mailing lists > Public > public-rdf-dawg@w3.org > April to June 2009

Re: negation (was: Question regarding subselect)

From: Steve Harris <steve.harris@garlik.com>
Date: Fri, 1 May 2009 14:53:38 +0100
Cc: 'RDF Data Access Working Group' <public-rdf-dawg@w3.org>
Message-Id: <D2237EFE-C66E-4DFD-A8E0-9C2DFC5A1091@garlik.com>
To: "Seaborne, Andy" <andy.seaborne@hp.com>
On 1 May 2009, at 13:55, Seaborne, Andy wrote:
>>>> Yes, that's my fault, I think I created that wiki page - SubQuery
>>>> would have been a better name, and was my intention. It's SQL  
>>>> legacy
>>>> where the only query verb is SELECT. Well... actually there's SHOW,
>>>> but it's a bit different and you can't do sub-shows.
>>>>
>>>> SubASKs don't have to go in a FILTER, they're also useful in WHERE
>>>> clauses, assuming they project either a solution with no bindings
>>>> (for
>>>> true) or no solutions (for false).
>
> On reflection (well, have to think of something on my lunchtime  
> run), I think it's a bit more involved for negation (!ASK) because  
> of variable scoping.  The usage I have in mind is that NOT EXIXTS  
> {pattern} is testing to see if the pattern does not match and the  
> variables in-scope include those from the previous part of the query  
> (it's not bottom up evaluation).  This form of negation is order  
> dependent as is OPTIONAL/!BOUND - NOT EXISTS has the same effect  
> except it does not rely on at least one free variable.  Without  
> assignment, NOT EXIST (in pattern or in filter) is much easier to  
> use than OPTIONAL/!BOUND.

That sounds like what I had in mind. I suspect that all subqueries are  
order-dependent.

> Let's sketch some examples around the F2F.  We probably in strong  
> agreement but using different words.

Yes, I suspect so.

- Steve
Received on Friday, 1 May 2009 13:54:14 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 16:15:38 GMT