Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save davidsbatista/30fdead90869539114bb892c2f22ab6c to your computer and use it in GitHub Desktop.
Save davidsbatista/30fdead90869539114bb892c2f22ab6c to your computer and use it in GitHub Desktop.
Electric power dams in Portugal
#defaultView:Map
SELECT DISTINCT ?dam ?name ?elevation ?coords WHERE {
# ?dam wdt:P31/wdt:P279* wd:Q12323 .
?dam wdt:P31/wdt:P279* wd:Q15911738 . # only hidroelectric cpower
?dam wdt:P17 wd:Q45 . # only located in Portugal
?dam rdfs:label ?name FILTER(LANG(?name) = "pt") .
?dam p:P2044 ?elevation_sea_level .
?elevation_sea_level ps:P2044 ?elevation .
?dam p:P625 ?coordinataes .
?coordinataes ps:P625 ?coords;
psv:P625 [
wikibase:geoLatitude ?lat;
wikibase:geoLongitude ?long
] .
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment