W3C home > Mailing lists > Public > public-rdf-dawg@w3.org > October to December 2010

Re: Aggregates question...

From: Axel Polleres <axel.polleres@deri.org>
Date: Thu, 7 Oct 2010 08:51:19 -0400
Cc: "SPARQL Working Group" <public-rdf-dawg@w3.org>
Message-Id: <860BF31C-506F-4496-BAFE-20E1A3EFC43B@deri.org>
To: "Steve Harris" <steve.harris@garlik.com>

On 7 Oct 2010, at 05:34, Steve Harris wrote:

> On 2010-10-07, at 02:31, Axel Polleres wrote:
> 
> > What happens when grouping for UNBOUND variables?
> >
> > E.g.
> >
> > Graph:
> > :s1 :p :o1.
> > :s1 :p :o2.
> > :s1 :q :o3.
> > :s2 :p :o1.
> > :s2 :p :o2.
> >
> > Query:
> >
> >  SELECT ?Q (COUNT(?P) as ?CP)
> >  WHERE { ?S :p ?P  OPTIONAL {?S :q ?Q } }
> >  GROUP BY ?Q
> >
> > My current understanding is:
> >
> >  that this returns
> >
> >   ?Q | ?CP
> >  =========
> >  :o3 | 2
> 
> That's correct. It could be made clearer in the text though.
> 
> > rather than
> >
> >   ?Q | ?CP
> >  =========
> >  :o3 | 2
> >      | 2
> >
> > yes?
> >
> >
> > In general, what is unclear to me is what ListEval returns when for ExprList = ?var and &mu;(?var) undefined?
> 
> ListEval(undefined) = error.

As far as I read it, this is not entirely clear from the current definition of ListEval...
ListEval takes an ExpressionList as input... ?Q is an expression list, 
if ?Q is not in the domain of &mu, it is not clear for me that 
&mu;(?Q) = error, it could likewise just be &mu;(?Q) = ?Q, or no?
At least I don't think it's clear from the current definition.

best,
Axel


> 
> > It seems, strictly following the definition &mu;(?var) would then just amount to ?var , then again, I don't know what that
> > should mean for the rest of the aggregation semantics?
> 
> I'm not sure I understand.
> 
> - Steve
> 
> --
> Steve Harris, CTO, Garlik Limited
> 1-3 Halford Road, Richmond, TW10 6AW, UK
> +44 20 8439 8203  http://www.garlik.com/
> Registered in England and Wales 535 7233 VAT # 849 0517 11
> Registered office: Thames House, Portsmouth Road, Esher, Surrey, KT10 9AD
> 
> 
Received on Thursday, 7 October 2010 12:51:58 GMT

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