Migrating from Oracle 19c to Postgres involves a number of steps. Here's a rough outline of the process along with some commands you can use:
Install Postgres on the target server.
Create a new database in Postgres:
createdb mynewdatabaseInstall the Ora2Pg tool on the source server:
arduinosudo apt-get install ora2pgGenerate the Ora2Pg configuration file:
cssora2pg --init_project myprojectEdit the configuration file to match your Oracle database:
bashvi myproject/ora2pg.confConvert the Oracle database schema to Postgres:
bashora2pg -t EXPORT_SCHEMA -c myproject/ora2pg.conf -o schema.sqlConvert the Oracle database data to Postgres:
bashora2pg -t EXPORT -c myproject/ora2pg.conf -o data.sqlTransfer the schema and data files to the target server.
Load the schema and data into Postgres:
graphqlpsql mynewdatabase < schema.sql psql mynewdatabase < data.sqlVerify that the data has been migrated correctly.
Update any application code that accesses the database to use Postgres instead of Oracle.
Note that this is a high-level overview and there may be additional steps or variations depending on the specific needs of your migration. It's also important to thoroughly test the new system before cutting over to it in production.
