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

Re: More on the evil examples... and "What really happened to Limit per Resource?"

From: Olivier Corby <Olivier.Corby@sophia.inria.fr>
Date: Mon, 09 Nov 2009 17:23:10 +0100
Message-ID: <4AF841EE.8070205@sophia.inria.fr>
To: Axel Polleres <axel.polleres@deri.org>
CC: SPARQL Working Group <public-rdf-dawg@w3.org>
In order to get one price per book, I suggest this  :

PREFIX  : <http://books.example/>
  SELECT SUM(?lprice) AS ?totalPrice
  WHERE {
    {select distinct ?org ?book where {
      ?org :affiliates ?auth .
      ?auth :writesBook ?book .}
    }
    ?book :price ?lprice
  }
  GROUP BY ?org
  HAVING (SUM(?lprice) > 10)



Olivier
Received on Monday, 9 November 2009 16:23:47 GMT

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