W3C home > Mailing lists > Public > public-rdf-dawg@w3.org > July to September 2004

Re: DISTINCT (was: Re: Queries over multiple graphs)

From: Steve Harris <S.W.Harris@ecs.soton.ac.uk>
Date: Tue, 28 Sep 2004 20:55:44 +0100
To: RDF Data Access Working Group <public-rdf-dawg@w3.org>
Message-ID: <20040928195544.GA19813@login.ecs.soton.ac.uk>

On Tue, Sep 28, 2004 at 06:19:29 +0100, Andy Seaborne wrote:
> I prefer to have explicit DISTINCT.  I don?t see having SELECT returning 
> duplicate rows contradicting RDF's set of statements if the app writer only 
> wants some of the variables.
> If there is no DISTINCT, then there is there is one result for every way 
> the query can be matched.  Because SELECT can remove variables, it is 
> possible the application can't tell two solutions (table rows, results) 
> apart - but it can if there is "SELECT *" or SELECT with all the variables. 
> "SELECT DISTINCT" means no two results the same even when there fewer 
> variables.  Hence "SELECT DISTINCT *" is a no-op.

Doesnt that assume that every statement in the system is unique at the
triple level? That is not neccesarily the case.
> Follwoign on, for optionals, thsi approach suggests a style of one query 
> result row for each way a query can match.
> E.g.: Separate optional blocks, separate variables:
> OPTIONAL ... ?x ....    // does not use ?y
> OPTIONAL ... ?y ....    // does not use ?x
> gives
> ?x = ...    // and no ?y
> ?y = ...    // and no ?x

What about ?x=NULL, ?y=NULL and ?x=... , ?y=..., would those also be valid
solutions? I think I'm not following this part. Possibly a more concrete
example would help.

- Steve 
Received on Tuesday, 28 September 2004 19:55:52 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:00:45 UTC