Linkedin

Migrate Oracle OUT bind variables to a PostgreSQL database

Project Overview

Project Detail

This pattern shows how to migrate Oracle Database OUT bind variables to either one of the following PostgreSQL-compatible AWS database services:

  • Amazon Relational Database Service (Amazon RDS) for PostgreSQL

  • Amazon Aurora PostgreSQL-Compatible Edition

PostgreSQL doesn’t support OUT bind variables. To get the same functionality in your Python statements, you can create a custom PL/pgSQL function that uses the GET and SET package variables instead. To apply these variables, the example wrapper function script that’s provided in this pattern uses an AWS Schema Conversion Tool (AWS SCT) extension pack.

Note: If the Oracle EXECUTE IMMEDIATE statement is a SELECT statement that can return one row at most, it’s a best practice to do the following:

  • Put OUT bind variables (defines) in the INTO clause

  • Put IN bind variables in the USING clause

For more information, see EXECUTE IMMEDIATE statement in the Oracle documentation.

https://docs.aws.amazon.com/prescriptive-guidance/latest/patterns/migrate-oracle-out-bind-variables-to-a-postgresql-database.html?did=pg_card&trk=pg_card

To know more about this project connect with us

Migrate Oracle OUT bind variables to a PostgreSQL database