【pgsql】How to reset sequence in postgres and fill id column with new data?
一。清除表
TRUNCATE table ex_statistics
二。The best way to reset a sequence to start back with number 1 is to execute the following
ALTER SEQUENCE <tablename>_<id>_seq RESTART WITH 1
So, for...
原创
2019-01-12 01:57:47 ·
238 阅读 ·
0 评论