I would like to develop a small geocoder using OpenStreetMap. Now I downloaded the file germany-latest.osm.pbf
and converted it with the tool pbf2json
into a JSON stream.
With this tool it is now possible to "pick" only JSON's with the planet type way
.
These contain the respective street, city, house number, postal code and the position, so everything I need for the geocoding.
But what I don't understand is that the file saarland-latest.osm.pbf
which has the state Saarland (the smallest state in Germany) has about 658548 ways and the file germany-latest.osm.pbf
has about 3792000 ways. Is there something wrong with the parser, or does "germany-latest.osm.pbf" only contain the "most important" roads in Germany, while the osm.pbf files of the different federal states contain all roads within the federal states?
So I have to download each state individually to get all streets of the whole country?