What is Star Schema?

A star schema is a way of modelling data for analysis, with a central fact table of events surrounded by dimension tables that describe them.

Star Schema explained

The fact table holds the measurable events, such as one row per sale with an amount and quantity. Dimension tables hold the descriptive context: who the customer was, which product, which date. Facts link to dimensions by keys, and the diagram looks like a star.

The design makes analysis queries simple and predictable: join the fact table to the dimensions you want and group by their attributes.

Example

A sales star has a sales fact table linked to customer, product, store and date dimensions, so you can total sales by product category and month.

Frequently asked questions

What is Star Schema?
A star schema is a way of modelling data for analysis, with a central fact table of events surrounded by dimension tables that describe them.
Can you give an example of Star Schema?
A sales star has a sales fact table linked to customer, product, store and date dimensions, so you can total sales by product category and month.