dbt Redshift
Table of Contents
- Getting Started
- Settings
-
Project Directory (
project_dir) -
Profiles Directory (
profiles_dir) -
Authentication Method (
auth_method) -
Cluster ID (
cluster_id) -
Host (
host) -
Password (
password) -
User (
user) -
Port (
port) -
Database (
dbname) -
Schema (
schema) -
IAM Profile (
iam_profile) -
IAM Duration Seconds (
iam_duration_seconds) -
Autocreate (
autocreate) -
Databse Groups (
db_groups) -
Keep Alives Idle (
keepalives_idle) -
Search Path (
search_path) -
SSL Mode (
sslmode) -
RA3 Node (
ra3_node)
-
Project Directory (
- Looking for help?
The dbt-redshift transformer uses SQL to transform data stored in your warehouse.
-
- Repository: https://github.com/dbt-labs/dbt-redshift
-
-
-
-
-
-
- Maintainer: dbt Labs
-
-
Getting Started #
Prerequisites #
If you haven't already, follow the initial steps of the Getting Started guide:
Installation and configuration #
Using the Command Line Interface #
-
Add the
dbt-redshifttransformer to your project usingmeltano add:meltano add transformer dbt-redshift -
Configure the settings below using
meltano config.
Next steps #
Follow the remaining steps of the Getting Started guide:
If you run into any issues, learn how to get help.
Settings #
Settings for dbt itself can be configured through dbt_project.yml as usual, which can be found at transform/dbt_project.yml in your Meltano project. dbt also has adapter-specific documentation for Redshift.
These and other supported settings are documented below. To quickly find the setting you're looking for, use the Table of Contents at the top of the page.
Project Directory (project_dir)
#
-
Environment variable:
DBT_REDSHIFT_PROJECT_DIR - Default:
$MELTANO_PROJECT_ROOT/transform
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set project_dir <project_dir>
export DBT_REDSHIFT_PROJECT_DIR=<project_dir>
Profiles Directory (profiles_dir)
#
-
Environment variable:
DBT_PROFILES_DIR, alias:DBT_REDSHIFT_PROFILES_DIR - Default:
$MELTANO_PROJECT_ROOT/transform/profiles/redshift
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set profiles_dir <profiles_dir>
export DBT_PROFILES_DIR=<profiles_dir>
Authentication Method (auth_method)
#
-
Environment variable:
DBT_REDSHIFT_AUTH_METHOD
The auth method to use (to use iam, set to “iam”. Omit to use password-based auth.)
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set auth_method <auth_method>
export DBT_REDSHIFT_AUTH_METHOD=<auth_method>
Cluster ID (cluster_id)
#
-
Environment variable:
DBT_REDSHIFT_CLUSTER_ID
The cluster id.
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set cluster_id <cluster_id>
export DBT_REDSHIFT_CLUSTER_ID=<cluster_id>
Host (host)
#
-
Environment variable:
DBT_REDSHIFT_HOST
The host for the cluster.
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set host <host>
export DBT_REDSHIFT_HOST=<host>
Password (password)
#
-
Environment variable:
DBT_REDSHIFT_PASSWORD
The password, if using password-based auth.
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set password <password>
export DBT_REDSHIFT_PASSWORD=<password>
User (user)
#
-
Environment variable:
DBT_REDSHIFT_USER
The user to connect as.
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set user <user>
export DBT_REDSHIFT_USER=<user>
Port (port)
#
-
Environment variable:
DBT_REDSHIFT_PORT
The port to connect to.
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set port 1234
export DBT_REDSHIFT_PORT=1234
Database (dbname)
#
-
Environment variable:
DBT_REDSHIFT_DBNAME
The name of the db to connect to.
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set dbname <dbname>
export DBT_REDSHIFT_DBNAME=<dbname>
Schema (schema)
#
-
Environment variable:
DBT_REDSHIFT_SCHEMA
The schema to use.
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set schema <schema>
export DBT_REDSHIFT_SCHEMA=<schema>
IAM Profile (iam_profile)
#
-
Environment variable:
DBT_REDSHIFT_IAM_PROFILE
The IAM profile to use.
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set iam_profile <iam_profile>
export DBT_REDSHIFT_IAM_PROFILE=<iam_profile>
IAM Duration Seconds (iam_duration_seconds)
#
-
Environment variable:
DBT_REDSHIFT_IAM_DURATION_SECONDS
Duration of the IAM session.
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set iam_duration_seconds 1234
export DBT_REDSHIFT_IAM_DURATION_SECONDS=1234
Autocreate (autocreate)
#
-
Environment variable:
DBT_REDSHIFT_AUTOCREATE
Whether or not to automatically create entities.
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set autocreate true
export DBT_REDSHIFT_AUTOCREATE=true
Databse Groups (db_groups)
#
-
Environment variable:
DBT_REDSHIFT_DB_GROUPS
Database groups to use.
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set db_groups '[...]'
export DBT_REDSHIFT_DB_GROUPS='[...]'
Keep Alives Idle (keepalives_idle)
#
-
Environment variable:
DBT_REDSHIFT_KEEPALIVES_IDLE
Seconds between TCP keepalive packets
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set keepalives_idle 1234
export DBT_REDSHIFT_KEEPALIVES_IDLE=1234
Search Path (search_path)
#
-
Environment variable:
DBT_REDSHIFT_SEARCH_PATH
The search path to use (use of this setting is not recommended)
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set search_path <search_path>
export DBT_REDSHIFT_SEARCH_PATH=<search_path>
SSL Mode (sslmode)
#
-
Environment variable:
DBT_REDSHIFT_SSLMODE
SSL MOde used to connect to Redshift.
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set sslmode '[...]'
export DBT_REDSHIFT_SSLMODE='[...]'
RA3 Node (ra3_node)
#
-
Environment variable:
DBT_REDSHIFT_RA3_NODE
Enables cross-database sources.
How to use #
Manage this setting using
meltano config or an
environment variable:
meltano config dbt-redshift set ra3_node true
export DBT_REDSHIFT_RA3_NODE=trueLooking for help? #
If you're having trouble getting the
dbt-redshift transformer to work, look for an
existing issue in its repository, file a new issue,
or
join the Meltano Slack community
and ask for help in the #plugins-general channel.
Found an issue on this page? #
This page is generated from a YAML file that you can contribute changes to. Edit it on GitHub!