Member-only story

Understanding dbt Modelling Layers and their Purpose

Alwyn Dsouza
2 min readNov 17, 2024

--

dbt (data build tool) is a powerful tool for transforming raw data into meaningful insights. It organizes data transformation into distinct layers, each serving a specific purpose. This structured approach ensures data is clean, consistent, and ready for analysis. Below, we delve into each layer in detail.

Landing Layer

Models — The landing layer, also called the raw zone or source layer, acts as the initial point of entry for data.

Structure — 1:1 reflection of source tables without any transformations.

Transformations — No Transformation.

Staging Layer

Models — Staging Models (stg_*): These models are responsible for transforming raw data from the source into a clean and consistent format. Staging layers is the replica of source with light column transformations.

Structure —Typically a 1:1 reflection of source tables. No joins between models in this layer.

Transformations — Light modifications like data type casting, column renaming, and (optional) filtering out deleted records.

Purpose — To cleanse, standardize, and prepare raw data for downstream consumption.

Intermediate Layer

--

--

No responses yet