udemy-complete-dbt-bootcamp/notes/8.md

20 lines
654 B
Markdown
Raw Normal View History

2023-10-30 16:57:30 +01:00
## Models
Models are the fundamental concept behind dbt.
They are stored as SQL files in the `models` folder.
2023-10-30 17:24:01 +01:00
Models can be related between themselves to map dependencies.
## Materializations
- Ways in which a model can be stored in the database. There are 4:
- View: it's just a view
- Table: the model gets stored as a table
- Incremental: also a table, but can only create new records, not update
- Ephemeral: it's actually NOT materializing. The model can be used by dependents, but it won't be materialized in the DB. It will truly only be a CTE that gets used by other models. Mostly for intermediate states in transformations.
##