Skip to content

How to handle ids for tables that should not auto-delete #2416

@joto

Description

@joto

Normal osm2pgsql tables have an id column and osm2pgsql make sure to delete objects from them if those objects are deleted or changed. But this is not always the case, especially with the new delete callbacks.

The current way to handle this is to not set a "magic" id column, but add an id column manually that osm2pgsql doesn't know about. But that seems counterintuitive and osm2pgsql will also print a warning about an id-less table.

I see two options:

  1. Add some option to the ids setting when creating the table, something like auto_delete=off or so.
  2. Add explicit id types to other types such as int, so that osm2pgsql can know that those special types are used as ids and remove the warning.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions