Skip to content

Instantly share code, notes, and snippets.

@Kimtaro
Created November 10, 2014 15:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Kimtaro/bde33d2ae6f71a5d74d7 to your computer and use it in GitHub Desktop.
Save Kimtaro/bde33d2ae6f71a5d74d7 to your computer and use it in GitHub Desktop.
SPARQL for DBpedia, stations in Tokyo
PREFIX dbo: <http://dbpedia.org/ontology/>
SELECT ?station, ?label, ?lat, ?long, ?location WHERE {
?station rdf:type <http://dbpedia.org/ontology/RailwayStation> .
?station <http://dbpedia.org/ontology/location> :Tokyo .
?station <http://dbpedia.org/ontology/location> ?location .
?station rdfs:label ?label .
?station <http://www.w3.org/2003/01/geo/wgs84_pos#lat> ?lat .
?station <http://www.w3.org/2003/01/geo/wgs84_pos#long> ?long .
FILTER (LANG(?label) = 'ja')
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment