dbt example project that shows dimensional modeling, metrics and other techniques

I put this project together a while ago to bring together various enterprise-level Business Intelligence techniques:

Here are some highlights:

  • shows some introductory dimensional modeling techniques
  • uses the dbt-labs/metrics package, showing a best-practice of how to build a wide table from your dimensional models
  • uses the calogica/dbt_date package to build a robust Date Dimension
  • uses the Snowflake-Labs/dbt_constraints (not just Snowflake) package to create primary and foreign key constraints, which can be used for joins/discovery even if the cloud data warehouse doesn’t use them
  • tested with Postgres, BigQuery, Snowflake, SQL Server, and Redshift adapters
  • shows how to use dbt as a semantic layer (not “the semantic layer” that works on Snowflake only) to define metrics, dimensions, aggregations, calculations, data relationships, business-friendly names and descriptions, synonyms, formatting and other data catalog attributes

It would be awesome to have people contribute and build out more complex dimensional modeling and other enterprise BI features.

5 Likes

This is very cool! Making a note to dig into it further :eyes: