0

Hello,

I would like to get a list of all german cities with its borders (as polygon) and name. I started to import the data into the database by using osmosis:

./osmosis --read-pbf file=/mnt/hgfs/VM-SharedFolder/germany.osm.pbf --tf accept-nodes place=village,town,city --tf accept-ways place=village,town,city --write-pgsql host=localhost database=DB_NAME user=USER password=PWD

This filled the database tables (nodes, relations etc.) but I do not know how to extract a polygon by using these data. Any hints?

Thank you, hem

asked 24 Sep '11, 13:05

hem's gravatar image

hem
1111
accept rate: 0%


2 Answers:
0

I cannot give you a concrete solution, but have a general look also at the blog of Jochen Topf about boundary relations.

And if you have more detailed questions I would even recommend to ask further at the German subforum at forum.osm.org

permanent link

answered 24 Sep '11, 13:49

stephan75's gravatar image

stephan75
12.5k454209
accept rate: 6%

0

What do you mean by "extract a polygon"? You can get the name and the polygon of all the municipalities boundaries from the database with such a query:

select name,way from "public".planet_osm_polygon where admin_level='8'

You can also download shapefiles from cloudmade or geofabrik

permanent link

answered 28 Sep '11, 10:26

NicolasDumoulin's gravatar image

NicolasDumoulin
3.3k42256
accept rate: 13%

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×585
×228
×76
×71

question asked: 24 Sep '11, 13:05

question was seen: 16,107 times

last updated: 28 Sep '11, 10:26

powered by OSQA