Skip to main content

iomete logo     dbt logo

Release Badge

dbt-iomete

The dbt-iomete package contains all the code enabling dbt to work with iomete.

This adapter is forked from the dbt-spark

Getting started

Installation

pip install dbt-iomete

Alternatively, you can install the package from GitHub with:

pip install "git+https://github.com/iomete/iomete-integrations.git#subdirectory=dbt-iomete"

Profile Setup

iomete:
  target: dev
  outputs:
    dev:
      type: iomete
      host: <host>
      port: 443
      https: true # or http
      dataplane: <iomete_dataplane>
      domain: <iomete_domain>
      lakehouse: <serverless_lakehouse_name>
      catalog: <catalog_name>
      schema: <database_name>
      user: "{{ env_var('DBT_IOMETE_USER_NAME') }}"
      token: "{{ env_var('DBT_IOMETE_TOKEN') }}"
      # optional: parallelism for listing relations in a schema (default 100)
      list_relations_threads: 100

list_relations_threads controls how many relations dbt describes in parallel when it lists a schema (via describe extended). It is independent of the global threads setting used to build models, so you can keep threads low while still listing schemas with many tables quickly. It defaults to 100; lower it if the data plane is under load, or omit it entirely to use the default.

Incremental strategies

IOMETE incremental models use Iceberg tables. Choose a strategy with the incremental_strategy config:

Strategy Behavior
merge (default) Updates rows that match the unique_key and inserts new rows.
append Inserts every row from the current run without changing existing rows.
delete+insert Deletes rows that match the current run's unique_key values, then inserts every row from the current run.
insert_overwrite Replaces the affected partitions, or the whole table when partition_by is not set.

Use delete+insert for duplicate keys

Use delete+insert when one run can return several rows with the same unique_key. Spark rejects those rows during a merge, but delete+insert keeps them. If you omit unique_key, this strategy behaves like append.

The delete and insert are separate statements, so the operation is not atomic. If the insert fails after the delete succeeds, rerun the model or perform a full refresh to restore the missing rows. Also note that incremental_predicates apply only to the delete. The insert still writes every row from the current run.

Replace partitions with insert_overwrite

Use insert_overwrite when each run returns the complete contents of every partition it updates. Rows already stored in an affected partition are removed, even if the current model result does not contain replacements for them.

For example, this model replaces only the calendar days returned by the current run:

{{ config(
    materialized='incremental',
    incremental_strategy='insert_overwrite',
    partition_by='days(event_time)'
) }}

select event_id, event_time, payload
from {{ ref('events') }}
{% if is_incremental() %}
where event_time >= current_date() - interval 1 day
{% endif %}

Partitions absent from the result stay unchanged. Iceberg hidden partition transforms such as days(event_time) and bucket(16, event_id) are supported. If you omit partition_by, the current result replaces every row in the target table.

The overwrite is one atomic Iceberg operation. Values map to target columns by name rather than source position, and a target column missing from the current model result receives NULL.

For more information, consult the docs.

Download files

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

Source Distribution

dbt_iomete-1.8.3.tar.gz (25.0 kB view details)

Uploaded Source

File details

Details for the file dbt_iomete-1.8.3.tar.gz.

File metadata

  • Download URL: dbt_iomete-1.8.3.tar.gz
  • Upload date:
  • Size: 25.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.12.14

File hashes

Hashes for dbt_iomete-1.8.3.tar.gz
Algorithm Hash digest
SHA256 335dd289809f8fabf11c90eec4e5073f67c4980edde7f0d07c399e6a613f0bbb
MD5 2decf9df414952c265e4ad6fef60f449
BLAKE2b-256 1a5e261a8bdcb5581db2ffb68a9144a221f100c1252acd256f2c0d0925795585

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

1.8.3 This release

1 file

1.8.2

1 file

1.8.1

1 file

1.8.0

1 file

1.7.9

1 file

1.7.8

1 file

1.7.7

1 file

1.7.6

1 file

1.7.5

1 file

1.7.4

1 file

1.7.3

2 files

1.7.2

2 files

1.7.1

2 files

1.7.0

2 files

1.5.0

2 files

1.4.0

2 files

1.2.0

2 files

1.1.0

2 files

1.0.2

1 file

1.0.1

2 files

1.0.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page