How to reset the sequence for IDs on PostgreSQL tables

后端 未结 9 931
北荒
北荒 2020-12-05 02:37

I recently imported a lot of data from an old database into a new Postgresql database as the basis for models in a new Django site.

I used the IDs from the old datab

9条回答
  •  春和景丽
    2020-12-05 03:15

    This snippet Run sqlsequencereset on all apps reset all IDs of all Empty Models

提交回复
热议问题