Created
April 7, 2017 04:25
-
-
Save tgroshon/c1b6335d8129179efe2da6f017a7562c to your computer and use it in GitHub Desktop.
Why does this cause a bunch of "SELECT * from my_table" queries to wait? How to make not locking?
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BEGIN; | |
ALTER TABLE "my_table" ADD COLUMN "some_field" text NULL; | |
ALTER TABLE "my_table" ALTER COLUMN "some_field" DROP DEFAULT; | |
COMMIT; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment