This plugin ports dbt functionality to IBM DB2.
This is an experimental plugin:
- We have not tested it extensively
- Only basic tests are implemented
- Compatibility with other dbt packages (like dbt_utils) is only partially tested
Please read these docs carefully and use at your own risk. Issues welcome!
This plugin can be installed via pip:
$ pip install dbt-ibmdb2
DB2 LUW | DB2 z/OS | Feature |
---|---|---|
β | π€· | Table materialization |
β | π€· | View materialization |
β | π€· | Incremental materialization |
β | π€· | Ephemeral materialization |
β | π€· | Seeds |
β | π€· | Sources |
β | π€· | Custom data tests |
β | π€· | Docs generate |
β | π€· | Snapshots |
Notes:
- dbt-ibmdb2 is built on the ibm_db python package and there are some known encoding issues related to z/OS.
A dbt profile can be configured to run against DB2 using the following configuration example:
Example entry for profiles.yml:
your_profile_name:
target: dev
outputs:
dev:
type: ibmdb2
schema: analytics
database: test
host: localhost
port: 50000
protocol: TCPIP
user: my_username
password: my_password
extra_connect_opts: my_extra_config_options
Option | Description | Required? | Example |
---|---|---|---|
type | The specific adapter to use | Required | ibmdb2 |
schema | Specify the schema (database) to build models into | Required | analytics |
database | Specify the database you want to connect to | Required | testdb |
host | Hostname or IP-adress | Required | localhost |
port | The port to use | Optional | 50000 |
protocol | Protocol to use | Optional | TCPIP |
user | The username to use to connect to the server | Required | my-username |
password | The password to use for authenticating to the server | Required | my-password |
extra_connect_opts | Extra connection options | Optional | Security=SSL;SSLClientKeyStoreDB=<path-to-client-keystore>;SSLClientKeyStash=<path-to-client-keystash> |
Make sure you have docker and poetry installed globally.
make install
make test
make uninstall
Want to report a bug or request a feature? Open an issue.
dbt-ibmdb2 is heavily inspired by and borrows from dbt-mysql and dbt-oracle.