Skip to content

pgsql-mid fails on relations with more than 32767 members #713

@lonvia

Description

@lonvia

pgsql-mid stores the member offset for relations in the planet_osm_rels table as smallints (way_off, rell_off columns). That means that the number of members it can safely handle is restricted to 32767. However, the limit is nowhere checked. Trying to import a larger relation leads to the error:

 Osm2pgsql failed due to ERROR: insert_rel failed: ERROR:  value "37945" is out of range for type smallint

This happened recently with relation 7066589.

osm2pgsql should drop relations that are too large early in the processing. What would a reasonable upper limit be?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions