Skip to main content

The Teradata adapter plugin for dbt (data build tool)

Project description

dbt-teradata

This plugin ports dbt functionality to Teradata Vantage.

Sample profile

Here is a working example of a dbt-teradata profile:

my-teradata-db-profile:
  target: dev
  outputs:
    dev:
      type: teradata
      host: localhost
      user: dbc
      password: dbc
      schema: dbt_test
      tmode: ANSI

At a minimum, you need to specify host, user, password, schema (database), tmode.

Optional configurations

Logmech

The logon mechanism for Teradata jobs that dbt executes can be configured with the logmech configuration in your Teradata profile. The logmech field can be set to: TD2, LDAP, KRB5, TDNEGO. For more information on authentication options, go to Teradata Vantage authentication documentation.

my-teradata-db-profile:
  target: dev
  outputs:
    dev:
      type: teradata
      host: <host>
      user: <user>
      password: <password>
      schema: dbt_test
      tmode: ANSI
      logmech: LDAP

Port

If your Teradata database runs on port different than the default (1025), you can specify a custom port in your dbt profile using port configuration.

my-teradata-db-profile:
  target: dev
  outputs:
    dev:
      type: teradata
      host: <host>
      user: <user>
      password: <password>
      schema: dbt_test
      tmode: ANSI
      port: <port>

Other Teradata connection parameters

The plugin also supports the following Teradata connection parameters:

  • account
  • column_name
  • cop
  • coplast
  • encryptdata
  • fake_result_sets
  • field_quote
  • field_sep
  • lob_support
  • log
  • logdata
  • max_message_body
  • partition
  • sip_support
  • teradata_values

For full description of the connection parameters see https://github.com/Teradata/python-driver#connection-parameters.

Supported Features

Materializations

  • view
  • table
  • ephemeral
  • incremental

Commands

All dbt commands are supported.

Custom configurations

General

  • Enable view column types in docs - Teradata Vantage has a dbscontrol configuration flag called DisableQVCI. This flag instructs the database to create DBC.ColumnsJQV with view column type definitions. To enable this functionality you need to:
    1. Enable QVCI mode in Vantage. Use dbscontrol utility and then restart Teradata. Run these commands as a privileged user on a Teradata node:
      # option 551 is DisableQVCI. Setting it to false enables QVCI.
      dbscontrol << EOF
      M internal 551=false
      W
      EOF
      
      # restart Teradata
      tpareset –y Enable QVCI
      
    2. Instruct dbt to use QVCI mode. Include the following variable in your dbt_project.yml:
      vars:
        use_qvci: true
      
      For example configuration, see test/catalog/with_qvci/dbt_project.yml.

Seeds

  • use_fastload configuration will instruct the plugin to use fastload when handling dbt seed command. You can set this seed configuration option in your project.yml file, e.g.:
    seeds:
      <project-name>:
        +use_fastload: true
    

Limitations

Transaction mode

Only ANSI transaction mode is supported.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dbt-teradata-0.19.0.5.tar.gz (21.5 kB view details)

Uploaded Source

Built Distribution

dbt_teradata-0.19.0.5-py3-none-any.whl (24.2 kB view details)

Uploaded Python 3

File details

Details for the file dbt-teradata-0.19.0.5.tar.gz.

File metadata

  • Download URL: dbt-teradata-0.19.0.5.tar.gz
  • Upload date:
  • Size: 21.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.23.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.12

File hashes

Hashes for dbt-teradata-0.19.0.5.tar.gz
Algorithm Hash digest
SHA256 9a002cb63d9f25c16b26f15654512aa8d9f9ade201843fa5972ab458a69bc5ae
MD5 dbe90fa9ed03b6dc51a919b6af0f9850
BLAKE2b-256 e879e3674a17733a6b57f0207d9118d4e1aac6cad42cd22467e0148a2e3350eb

See more details on using hashes here.

File details

Details for the file dbt_teradata-0.19.0.5-py3-none-any.whl.

File metadata

  • Download URL: dbt_teradata-0.19.0.5-py3-none-any.whl
  • Upload date:
  • Size: 24.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.23.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.12

File hashes

Hashes for dbt_teradata-0.19.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 4379e8b82f4e39b9aa432841f695e7f30cfb526f0ac7ca1144f303cf68987fe2
MD5 ba0871a8dd0a69981e0165318af9720b
BLAKE2b-256 15440ec6c5e4e260c5c3cde64df8d4a766d7f1d292fc3ea8e4d26143490ac3be

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page