Hello Dear All, I would like to export a .osm file in which only the Motorways (which are shown in red in open street map) are available for a whole small country like Belgium. How can I export the above-mentioned file from the open street map? Thank you all in advance for helping me with this issue. Regards, Behzad asked 02 Apr '20, 10:48 Behzad |
You can run this Overpass query in OverpassTurbo (the link takes you there). Then press Run (or Execute, I have the UI in Dutch). Then click Export and choose the format you need. answered 02 Apr '20, 13:50 escada 1
You might want to add highway=motorway_link to also fetch the interlinks of crossing motorways if you need those. It will also give you the ramps on/off the motorway, though. In the end you might need to do some cleaning.
(02 Apr '20, 14:37)
TZorn
Thank you very much for providing the links. it is very healful.
(02 Apr '20, 14:38)
Behzad
To be able to export to OSM format we need the query result in xml. Try the updated query. I also added lines to include motorway links and primary highways. This extract could become huge. So watch out when trying to run it (I didn't). You can remove the respective lines again if you want.
(02 Apr '20, 15:27)
TZorn
Dear TZom, Thank you very much. I really appreciate your favor. This is exactly what I want! Besides, How can I add other elements (for instance: railways)!? Regards,
(03 Apr '20, 10:11)
Behzad
|
To expand on your additional question (How can I add other elements (for instance: railways)!?): Objects in OSM are attributed by a main tag. For any sorts of highways that is Maybe worth noting that sometimes these features are not mapped as simple lines but as multipolygons. Then you would have to query not only for answered 03 Apr '20, 10:30 TZorn Thank you again dear TZorn, I tried to make some modification in the quarry that you provided and I come up with the above error: "An error occured during the execution of the overpass query! This is what overpass API returned: Error: runtime error: […] Please check /api/status for the quota of your IP address." Besides, is it possible to indicate a specific speed limit for a highway type?
(03 Apr '20, 14:58)
Behzad
1
There are some limits on usage so not to overload the servers. Best contact the server maintainers to find out more (if no one reading here knows more than me).
(03 Apr '20, 17:06)
TZorn
Thank you very much
(06 Apr '20, 08:50)
Behzad
That's because you're downloading 60mb each time you run it. Try this: http://overpass-turbo.eu/s/SCQ [bbox:{{bbox}}]; way[highway~"^(motorway|motorway_link|primary)$"]; out geom; bbox limits the output to the size of your window. out:xml isn't really required as it's converted when you export it as raw OSM data.
(09 Apr '20, 15:18)
DaveF
|