Skip to content

dbt practice problems

15 free dbt interview problems: write models with source() and ref(), Jinja, macros, data tests and incremental models, graded on hidden tests.

Sources & staging

source(), renaming and casting, null-safe filters and deduplicating change data.

Refs & marts

ref(), joining staging models into one row per entity without fan-out.

Jinja, vars & packages

loops, if blocks, var(), target and dbt_utils macros.

Macros

reusable SQL with arguments and defaults.

Data tests

singular tests and generic tests that return failing rows.

Incremental models

is_incremental(), {{ this }}, unique_key, strategies and late data.

PySpark problems · Learn