This is a static archive of our old OpenStreetMap Help Site. Please post any new questions and answers at community.osm.org.

For a newbie, converting OSM to CSV using OSMConvert.exe, what command line do I use?

0

I have installed osmconvert.exe, put it in the same folder as the .osm file, but now I can't figure out what code exactly to write to convert it to .csv (even though i've read the help pages) Ive been running the .exe file, then typing into the box: (taken from https://wiki.openstreetmap.org/wiki/Osmconvert#Writing_CSV_Files) country.osm -o=country.csv ...or... country.osm --all-to-nodes -o=country.csv ..or... country.osm --all-to-nodes --csv="@id @lat @lon" -o=country.csv and many variations thereof. But none of these work, the box just disappears! What am I doing wrong? Thankyou :)

asked 13 Dec '12, 10:07

jas1405's gravatar image

jas1405
11336
accept rate: 0%

2

Can you create a pastebin with your exact typing and the exact output?

http://pastebin.com/

(13 Dec '12, 13:30) Sanderd17

One Answer:

2

Are you sure to have started osmconvert from the command line? The interactive user interface "Bert" is not able to handle .csv functions. Thus you better should not start osmconvert by doubleclick if you want to create .csv output.

Please open a command line window change into your directory (use "cd" command) and enter for example:

osmconvert country.osm --csv="@id @lat @lon name amenity" -o=country.csv

answered 13 Dec '12, 21:18

Marqqs's gravatar image

Marqqs
448510
accept rate: 22%

many many thanks

(23 Apr '14, 08:48) say_hello_to...

can i apply this and - additionally get the tags for adress too

(23 Apr '14, 08:53) say_hello_to...

Source code available on GitHub .