Using http://dbpedia.org/sparql, I want to receive the geographic coordinates of all bank buildings. The list of classes tells me that I should query for Bank
.
Yet, the following code yields nothing:
SELECT DISTINCT ?label ?lat ?long
WHERE {
[]
rdf:type dbpedia-owl:Bank ;
geo:lat ?lat ;
geo:long ?long ;
rdfs:label ?label.
FILTER (LANGMATCHES(LANG(?label), 'en'))
}
If instead I query for any sibling to Bank
, (e.g. Brewery
or LawFirm
), I see at least some results. What's wrong with above code?
If you look into a dbpedia page for a bank, you can see that instead on
rdf:type
, banks have a propertydbpedia-owl:industry
that hasdbpedia:Bank
(Refah bank) ordbpedia:Financial_services
(Cyprus bank) as a value. So if you rewrite your query as the following, you will get some results:If you add
dbpedia:Financial_services
, other organisations such as London stock exchange will also appear:Again, by examining the London stock exchange, you can see that there is a product property that separates these financial institutions. So this will give you banks, but it might not cover all the banks available: