SPARQL Examples – Paging

Posted on Aug 31, 2017 (last modified Jun 18, 2021)

Retrieve the second page of names and emails of people in Tim Berners-Lee’s FOAF file, given that each page has 10 people. Try this on ARQ.

PREFIX foaf:<http://xmlns.com/foaf/0.1/> SELECT ?name ?email FROM <http://www.w3.org/People/Berners-Lee/card> WHERE { {SELECT DISTINCT ?person ?name WHERE { ?person foaf:name ?name } ORDER BY ?name LIMIT 10 OFFSET 10 } OPTIONAL { ?person foaf:mbox ?email } }