Please note that our Postgres destination is currently in open beta. The information in this article is subject to change.
As we mentioned when you created the instance, the credentials used to launch the instance belong to the master user, or admin. If you want to control the permission settings, you'll need to create an additional database user for Stitch.
While you can create a Postgres user for us at any time, we highly recommend doing so before any data is replicated into your data warehouse. The process for creating a user for us after replication has taken place is considerably lengthier than what's required for a new connection.
You must be a superuser (or have the
CREATEROLE permission) to create a Postgres user. Please contact your technical team if you’re not sure what this means or how to proceed.
To successfully pipe your data to your Postgres destination, the Stitch user needs permission to:
CREATEschemas, tables, and views
SELECTfrom systems tables
ALTER TABLEcommands to properly insert your data.
Restricting the Stitch user to a single schema or revoking public access to tables in the information schema will prevent Stitch from functioning properly. If you'd like guidance or more info on why we need these permissions, please reach out to us.
Connect to your Postgres instance using your SQL client. Note that anything inside the square brackets -
[like this] - is something you need to define when running the commands yourself.
After connecting, run this command to create the user:
create user [stitch_username] with password '[password]';
Next, you'll assign the
CREATE permissions to the user. For
[database name], enter the name of the database you created in step 2 of this tutorial:
grant create on database [database_name] to [stitch_username];
If you restricted access to the information schema in your instance, you'll also need to run this command to grant the Stitch user
grant select on all tables in schema information_schema to [stitch_username];
In the next step, you'll complete the setup by entering the Postgres-RDS' connection details into Stitch.