Hi,

I have some questions about the osm2pgsql and it's output to the
tables <<osm>>_line, <<osm>>_polygon and <<osm>>_rels (hereby called
tables line, polygon and rels).

After loading OSM data there are three remarkable things in the
resulting tables regarding osm_ids:

1. In the tables lines and polygons there exist rows with negative osm_ids.
2. Tables lines and polygons contain rows with duplicate osm_ids and
identical attributes except geometry.

I'd explain the first observation (negative osm_ids) by the following:
The original (positive) id comes from a relation including its tags.
So, given e.g. a multi-line or a multi-polygon relation which referrs
to two ways it's clear that there is one (relation) id split into two
rows in line/polygon table with the same (now negative) osm_id and
with different geometries each.

Table polygon has duplicate osm_ids like lines table but only with
negative ones. But lines table also contains positive osm_ids!

=> Why this duplicate positive osm_ids in lines?

In original OSM database there is no relation and only one way id (see
e.g. http://www.openstreetmap.org/browse/way/47926394 and compared
this to "select id, tags, length(way) from osm_line where id=47926394"
which will return three rows).

3. Then in table <<osm>>_rels which I don't understand following attributes:
* way_off (smallint)
* rel_off (smallint)
* pending (boolean) -- exists also in table osm_ways
* parts (integer[])
* members (text[])

=> Any hints?

Yours - S.

_______________________________________________
dev mailing list
dev@openstreetmap.org
http://lists.openstreetmap.org/listinfo/dev

Reply via email to