How to add increment primary key in an existing PostgreSQL table? #8784
Answered
by
adas98012
DesmondSol
asked this question in
Question
-
when creating my tables in the hasura console i forgot to make the id auto incremental for all the tables i used and after that when i tried to change them all to that there wasn't any easy way available i could find so i had to create alter statements for all the tables on the raw sql to do my tasks but since that is a lot of work can i ask if there is a better way already made. i used this code to make every change for all 35 tables that i had
|
Beta Was this translation helpful? Give feedback.
Answered by
adas98012
Aug 25, 2022
Replies: 1 comment 1 reply
-
Please see if the following discussion thread is helpful to your case: |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
adas98012
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Please see if the following discussion thread is helpful to your case:
https://dba.stackexchange.com/questions/285869/add-auto-increment-to-already-existing-primary-key-column-postgresql