Thursday, July 22, 2010

Star Schema vs. Snowflake Schema

Star Schema

• Start schema is simpler and hence good to use for small data warehouses. The rules that apply here are as follows:
• Each dimension is represented by a single dimension table
• Each dimensional table is related to or linked to a fact table.
• The relation is merely a master and detail relationship with Primary key being the dimension and reference key in the fact table.
• When there are 5 or more dimensions referring to one fact table it appears like a star and hence the name star schema
• In terms of ease of use you need less complex queries and easy to understand
• This design has redundant data and hence hard to maintain and change.
• Lesser query execution time due to lesser number of queries


Snowflake Schema
• Snowflake schema starts like a star schema and more complex and hence it is good to use the snow flake schema for large data warehouses. The rules that apply here are as follows:
• Each dimension is represented by a two or more dimension tables
• Each dimensional table is not directly related to fact table
• Here the tables that describe the dimensions are normalised.
• In terms of ease of use you have to use more complex queries
• There is no redundancy and easy to maintain and change
• More query execution time because of more foreign keys

No comments:

Free Power BI Classes Online -- Week 1

Today I have started free Power BI classes These classes are aimed at people who are new to Power BI.  I will be covering the Dashboard in a...