Data & AI

dbt

dbt versions SQL models, tests, and documentation so warehouse tables have owners, grain, and CI, not a folder of unreviewed scripts.

01What it is

In production terms.

dbt compiles select statements into models with dependencies, schema tests, and generated docs. It runs in CI and in the warehouse, turning analytics engineering into a reviewed software practice.

Codeaxes uses dbt when Project Data work needs more than a dashboard on raw exports. Models, tests, and documentation are how a metric survives a new analyst joining the team.

02Fit

Best-fit use cases.

  1. 01Staging, core, and mart layers for product events
  2. 02Finance-grade revenue tables with uniqueness tests
  3. 03Shared metric models consumed by BI tools
  4. 04CI that fails when a grain or not-null contract breaks

03Trade-offs

Benefits and limits.

Benefits

  • Lineage and docs generated from the same project as the SQL
  • Tests that fail the job when data contracts break
  • Pull requests for model changes, like application code
  • Fits BigQuery, Snowflake, Redshift, and Postgres warehouses

Limitations

  • Does not replace ingestion; it models data already in the warehouse
  • Poorly named models become a second undocumented codebase
  • Orchestration still needs Airflow, Cloud Composer, or similar

04Ecosystem

Compatible technologies.

05In the field

Example applications.

  • Product analytics marts with session and funnel grain documented
  • Operations SLA tables joining orders, exceptions, and clocks
  • Customer 360 models with match-rule documentation

Use dbt on a Codeaxes engagement.