SpinTheMic
Pro

Interview practice question

Same logic for five regional sources

Data Engineering · dbt · Experienced

Five regions have identical source systems in different schemas. You need the same models for each. How do you avoid five copies of the code?

What a strong answer covers

Your AI report card counts how many of these ideas you cover.

  • Union sources in staging with a region column, then model once.
  • dbt_utils.union_relations helps combine similar tables.
  • Or loop over a list of regions in Jinja to build unioned staging.
  • Keep region-specific quirks in small override models.
  • Separate projects or packages if regions need independent deploys.
Practise this topic

Start without signing up. Sign in free to get an AI report card on your answer.

See all topics