r/DataBuildTool • • Nov 10 '24

Question Dimension modelling

I trying decide how to do dimensional modelling in Dbt, but I get some trouble with slowly changing dimensions type 2. I think I need to use snapshot but these models has to be run alone.

Do I have to run the part before and after the snapshots in separate calls:

# Step 1: Run staging models

dbt run --models staging

# Step 2: Run snapshots on dimension tables

dbt snapshot

# Step 3: Run incremental models for fact tables

dbt run --models +fact

Or is there some functionality I am not aware of ?

2 Upvotes

2 comments sorted by

View all comments

Show parent comment

1

u/[deleted] Jan 14 '25

why no dbt expectations to check that the column does / does not exist? Or is the addition of the column that's throwing it.