- Dimensions and fact tables
Dimensions: Dimension table contains the descriptive attribute of the data. For Example Product Details will be there in the Product table.
A dimension table contains dimensions of a fact.
They are joined to a fact table via a foreign key.
Ex: Product table, Employee table, Calendar.
Fact: Fact table is a measurement of a subject. For example, sales amount would be a measure and this measure is stored in the fact table. It can be the sales amount by each store, each day or Product. A Fact Table contains foreign keys to the dimension tables.
Ex: Sales Fact, Inventory table
- Dimensional modeling
The main goal of this modeling is to improve the data retrieval. It is optimized for the SELECT operation. Dimensional data modeling is best suited for the data warehouse star and snowflake schema. This model gives us the advantage of storing data in such a way that it is easier to store and retrieve the data once stored in the data warehouse.