cz-full-spoi-construct-better-sfWithin.sparql 1.1 KB

12345678910111213141516171819202122232425262728293031
  1. PREFIX geo: <http://www.opengis.net/ont/geosparql#>
  2. PREFIX geof: <http://www.opengis.net/def/function/geosparql/>
  3. PREFIX virtrdf: <http://www.openlinksw.com/schemas/virtrdf#>
  4. PREFIX poi: <http://www.openvoc.eu/poi#>
  5. PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
  6. PREFIX olu-instance: <http://w3id.org/foodie/olu/LandUse/22165431>
  7. PREFIX foaf: <http://xmlns.com/foaf/0.1/>
  8. PREFIX dc: <http://purl.org/dc/elements/1.1/>
  9. PREFIX poi: <http://www.openvoc.eu/poi#>
  10. PREFIX dct: <http://purl.org/dc/terms/1.1/>
  11. PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
  12. PREFIX locn: <http://www.w3.org/ns/locn#>
  13. ### WORKS WITH SMALL NUMBER OF TRIPLES, WILL ALL TRIPLES IT DOES NOT WORK
  14. CONSTRUCT {?Resource ?p ?o }
  15. FROM <http://www.sdi4apps.eu/poi.rdf>
  16. WHERE {
  17. ?Resource ?p ?o .
  18. GRAPH ?g {
  19. SELECT DISTINCT ?Resource FROM <http://www.sdi4apps.eu/poi.rdf> WHERE { ##
  20. ?Resource a ?POI_Class .
  21. ?Resource geo:sfWithin <http://dbpedia.org/resource/Czech_Republic> .
  22. } ORDER BY ASC(?Resource) ###
  23. }
  24. }
  25. GROUP BY ?Resource ?p ?o
  26. #ORDER BY ?Resource
  27. #OFFSET 0
  28. LIMIT 100000