Ultimate Script to complete PostgreSQL-to-PostgreSQL Migration right after AWS DMS task done
Sequence, Foreign key, Index, and Constraint are available for migration.
- Sequence, Foreign key, Index, and Constraint are not migrated using AWS DMS.
- You must need them if you want to promote the target DB as primary.
- This script is responsible for completing a migration by putting them into your target DB.
git clone https://github.com/sinwoobang/dms-psql-post-data.git
npm -i g zx
- Run sequences_generator.sql on your source DB.
- Copy the result and run it on the target DB.
- Copy a template file
cp info-template.js info.js
- Revise info.js
- zx index_constraint_migration.mjs