StackNoob
StackNoob

Reputation: 73

DBpedia get all cities in the world - missing a few

I use this sparql query to get as much cities as possible:

select * where {
    ?city rdf:type dbo:PopulatedPlace
}

However, some expected ones are missing e.g.

http://dbpedia.org/resource/Heidelberg (neither that nor one of its wikiRedirects)

which is of a dbo:PopulatedPlace as this query returns true (in JSON):

ask {
    :Heidelberg a dbo:PopulatedPlace
}

I need that list to be exhaustiv because later I will add constraints based on user input.

I use http://dbpedia.org/snorql/ to test the queries.

Any help is appreciated.

UPDATE: One of the Devs told me the public endpoint is limited ( about 1K ). I'll come up with a paginated solution and see if it contains the 'outlier'.

UPDATE2: The outlier is definitly in the resultset of rdf:type dbo:Town. Using dbo:PopulatedPlace yields too many results to check per hand, though.

Upvotes: 2

Views: 313

Answers (1)

StackNoob
StackNoob

Reputation: 73

The public endpoint limits results to about 1K. Pagination or use of a smaller subclass of dbo:PopulatedPlace yields the result.

Upvotes: 4

Related Questions