One Model Per Source Table Rule in dbt
📖 Scenario: You work as a data analyst in a company that collects sales data from multiple stores. Each store's raw data is stored in separate source tables in your data warehouse. To keep your data models clean and easy to maintain, you want to follow the one model per source table rule in dbt.This means you will create one dbt model for each source table, transforming the raw data step-by-step.
🎯 Goal: Build dbt models that follow the one model per source table rule by creating a model for each source table and then combining them in a final model.You will start by defining source tables, then create models for each source, and finally create a combined model that joins the data.
📋 What You'll Learn
Define source tables in dbt source configuration
Create one dbt model per source table
Create a final dbt model that joins the individual models
Use simple SQL SELECT statements in models
💡 Why This Matters
🌍 Real World
In real companies, raw data often comes from many tables. Creating one model per source table helps organize transformations clearly and makes debugging easier.
💼 Career
Data analysts and engineers use dbt to build reliable data pipelines. Understanding this rule is key to writing clean, maintainable dbt projects.
Progress0 / 4 steps