Bird
0
0

In dbt, what does the built-in Jinja context variable this represent?

easy📝 Conceptual Q1 of 15
dbt - Jinja in dbt
In dbt, what does the built-in Jinja context variable this represent?
AThe current model being compiled
BThe timestamp when the run started
CThe unique identifier for the current run
DThe list of all models in the project
Step-by-Step Solution
Solution:
  1. Step 1: Understand the role of this in dbt

    this refers to the current model or resource being compiled or executed in dbt.
  2. Step 2: Compare with other context variables

    Other variables like run_started_at or invocation_id represent run metadata, not the model itself.
  3. Final Answer:

    The current model being compiled -> Option A
  4. Quick Check:

    this = current model [OK]
Quick Trick: Remember: this always points to the current model [OK]
Common Mistakes:
MISTAKES
  • Confusing this with run metadata variables
  • Assuming this is a timestamp
  • Mixing this with project-wide variables

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More dbt Quizzes