Created
November 26, 2017 11:20
-
-
Save eriknaslund/d02913262adca811ad3ecdd080db5780 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| -- This works on a normal postgres install, but on RDS it errors out with something similar too: | |
| -- ERROR: permission denied: "RI_ConstraintTrigger_a_6654774" is a system trigger | |
| -- It seems like rds_admin isn't admin enough... | |
| ALTER TABLE accept_language DISABLE TRIGGER all; | |
| -- This apparently disables all foreign keys for the current session. | |
| -- Too bad we can't ask DMS to execute it before starting the migration. | |
| SET session_replication_role = replica; | |
| -- Luckily enough we can set the above thing using a so called "parameter group" in RDS. | |
| -- It's a dynamic setting so it doesn't require an instance restart either. | |
| -- Once that setting is changed you can verify that it's correct by issuing: | |
| SHOW session_replication_role; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment