Skip to the workspace
Pebellslearn by building
Data Modeling  ›  Lesson

Star vs Snowflake Schema

Star vs Snowflake Schema 12 minA star schema joins every flattened dimension directly to the fact, while a snowflake chains dimensions to other dimensions, and Power BI generally works best with a star.

power bi / Star vs Snowflake Schema

Explore each scene at your own pace.

01 · The rule

The rule

Star vs Snowflake Schema

The till database stores products the tidy way a database likes: Products has a CategoryID that points to a Categories table, which has a DepartmentID that points to a Departments table. Arjun loads all three exactly as they are. The field list fills with near-empty tables, and a filter on Department has to travel through three relationships before it reaches Sales. There is a better shape for Power BI.

The rule

Star: every dimension one hop from the fact. Snowflake: dimensions chained to dimensions.

  • In a star schema, the fact table sits in the middle and every dimension joins straight to it. Dimensions are flattened: Products holds Product, Category and Department as ordinary columns.
  • In a snowflake schema, a dimension is split into a chain of smaller tables — Products → Categories → Departments — the way source databases often store them to avoid repeating text.
Star:       Stores ─── Sales ─── Products (Product, Category, Department)
                         │
                        Date

Snowflake:  Stores ─── Sales ─── Products ─── Categories ─── Departments
                         │
                        Date

Power BI works best with a star:

  • fewer relationships to maintain, and fewer tables in the field list for report builders;
  • filters travel one hop instead of several, so the model is simpler to reason about and usually faster;
  • the repeated category text in a flattened Products table costs little, because the model's column store compresses repeated values very well.

To flatten a snowflake, work in Power Query. Merge Categories into Products on CategoryID and expand the category name; then merge Departments on DepartmentID and expand the department name. Finally, right-click the Categories and Departments queries and untick Enable load. They still feed the merge, but they no longer appear as tables in the model.

Scene 1 of 5
Hover to wake the cannons. Drag to move, or use arrow keys when focused. Press Enter to fire a shot.