Created
December 12, 2017 11:06
-
-
Save northernjamie/f874261b2e8ea7d9b8dc2d723cdbf758 to your computer and use it in GitHub Desktop.
SPARQL query that powers the Google Chart demo with two series of data from OpenDataCommunities - rough sleepers in Brighton and Manchester
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#> | |
SELECT ?periodlabel ?countb ?countm | |
WHERE { | |
?obsm <http://purl.org/linked-data/cube#dataSet> <http://opendatacommunities.org/data/homelessness/rough-sleeping/count> ; | |
<http://opendatacommunities.org/def/ontology/geography/refArea> <http://opendatacommunities.org/id/geography/administration/md/E08000003> ; | |
<http://opendatacommunities.org/def/ontology/time/refPeriod> ?perioduri ; | |
<http://opendatacommunities.org/def/ontology/homelessness/roughSleepingObs> ?countm . | |
<http://opendatacommunities.org/id/geography/administration/md/E08000003> rdfs:label ?aream . | |
?obsb <http://purl.org/linked-data/cube#dataSet> <http://opendatacommunities.org/data/homelessness/rough-sleeping/count> ; | |
<http://opendatacommunities.org/def/ontology/geography/refArea> <http://opendatacommunities.org/id/geography/administration/ua/E06000043> ; | |
<http://opendatacommunities.org/def/ontology/time/refPeriod> ?perioduri ; | |
<http://opendatacommunities.org/def/ontology/homelessness/roughSleepingObs> ?countb . | |
<http://opendatacommunities.org/id/geography/administration/ua/E06000043> rdfs:label ?areab . | |
?perioduri rdfs:label ?periodlabel . | |
} | |
ORDER BY ?periodlabel |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment