You are not logged in.

#1 2020-10-07 10:23:27

Registered: 2020-08-20
Posts: 3

Download information from database

Hi everyone,

I am new to OSM and need help with an issue. In the tutorial I have seen that when creating a new element, it is necessary to specify what type it is: if it is a point: a tree, bank, signal, traffic light...; if it is a line: road, track, path...; and if it is an area: building (home, school...), hospital, etc. So, I would like to know if I can access a database in which all points, lines or areas by type of element appear for all of a city/state..., that is, all homes, all banks, all churches, all schools, etc., in order to filter more easily and be able to export to the QGIS program or maybe Excel.

Thanks in advance.


#2 2020-10-07 13:16:52

Registered: 2009-01-11
Posts: 534

Re: Download information from database

There are several ways of doing this (roughly in order of learning curve):

* Use overpass-turbo to query all elements within a bounding box (or a defined geographical area if available (e.g., city limits). In many cases the data may be too large for the web-browsers, but queries can be converted to overpass & something like wget or curl used. You can try with a small city, here Connoquenessing, in PA, but where things are mapped in detail the data volume can soon get large.
* Use a website offering smaller scale extracts. BBBike is one I use, but I think there are others. Link
* Get a larger extract (normally from Geofabrik Downloads), e.g., for a whole state, and use desktop tools such as osmosis or osmconvert to get the area you want.

You'll notice that objects which traverse the boundary are usually not truncated at the boundary, so you may need to cut these yourself (tools like og2ogr, or QGIS can be used). Overpass allows discrete sets of data (e.g., buildings or highways) to be downloaded and for many purposes a set of such extracts may be suitable.


Board footer

Powered by FluxBB