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

LIMIT problem (Paging)

From: Mirko <idonthaveenoughinformation@googlemail.com>
Date: Sat, 23 May 2009 18:41:23 +0200
Message-Id: <753BDD56-FF1D-45F1-805D-4B997FC4EA47@googlemail.com>
To: public-sparql-dev@w3.org
Hi all,
I have an understanding problem with paging (limit/offet) in Sparql.

Consider the following query:

Select ?userID ?itemID ?date WHERE {
   ?user my:hasUserID ?userID
.. ?user my:owns ?item
.. ?item my:hasItemID ?itemID
.. ?item my:soldToUser ?date
.. FILTER (?date > 20090101)
LIMIT 1000

A user might own multiple items.

The results are to large to keep in memory, so I would like to page  
them using LIMIT and OFFSET. However it does not work with the above  
query. The query above needs all results to be loaded into memory when  
evaluating it. I assume this is because more than one statement is  
evaluated in the WHERE clause(?).

So, how could I page the above query?

Thanks, Mirko
Received on Monday, 25 May 2009 06:18:49 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:15:50 UTC