Bird
0
0

You need to build a dbt model that combines data from customers and orders source tables. How should you structure your dbt models following the one model per source table rule?

hard📝 Application Q8 of 15
dbt - Project Organization
You need to build a dbt model that combines data from customers and orders source tables. How should you structure your dbt models following the one model per source table rule?
ACreate multiple models that join <code>customers</code> and <code>orders</code> in different ways
BCreate a single model that directly joins both source tables <code>customers</code> and <code>orders</code>
CCreate one model that selects from <code>customers</code> and another that selects from <code>orders</code>, without joining them
DCreate separate models for <code>customers</code> and <code>orders</code>, then build a third model that joins these two models
Step-by-Step Solution
Solution:
  1. Step 1: Follow the rule

    Each source table should have its own model, so create one for customers and one for orders.
  2. Step 2: Combine models

    To join data, create a separate model that references these two models, not the raw source tables directly.
  3. Final Answer:

    Create separate models for customers and orders, then build a third model that joins these two models -> Option D
  4. Quick Check:

    Separate source models, then join [OK]
Quick Trick: Join models, not source tables directly, to follow the rule [OK]
Common Mistakes:
MISTAKES
  • Joining source tables directly in one model
  • Not creating separate models per source table
  • Creating multiple join models unnecessarily

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More dbt Quizzes