New: Cookbooks and AI ExplanationsStep-by-Step recipes to solve problems connected to Roadmaps and Cheat Sheets. Need more details? Use AI buttons for structured and simple explanations with concrete examples throughout the whole platform.Take a look
The same currency-conversion CASE statement is pasted into six models, and I just fixed a bug in one copy without touching the other five.
What you'll have at the end
One dbt macro every model calls, with the six pasted copies of the same SQL deleted
You need
A dbt project where the same currency-conversion CASE block is already pasted into more than one model.
Not covered
Swapping the fixed conversion rates baked into the CASE block for a live rates table that updates on a schedule.
Checked 25 Aug 2026
Part of the dbt (Data Build Tool) cookbook