Redshift Truncate table and reset Identity?

喜夏-厌秋 提交于 2021-02-08 10:18:02

问题


I know in PostgresQL there is

truncate table restart identity;

but this doesn't work in Redshift. Is there something else to do this in Redshift? Otherwise I see it lot of pain to drop table and recreate and load.


回答1:


Its not possible to reseed identity value in redshift like other sql databases. you have to create new table and move data there.



来源:https://stackoverflow.com/questions/64530857/redshift-truncate-table-and-reset-identity

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!