A fact table in a
Following are the three types of fact tables:
Transaction fact table
Snapshot fact table
Accumulating snapshot fact table
A transaction fact table captures detailed information about individual business transactions or events. It records every occurrence at the most
Consider a retail business with a transaction fact table capturing sales data. The table may include the following columns:
Transaction ID | Product ID | Customer ID | Quantity | Unit price | Total sales |
1000 | 100 | 200 | 2 | 10 | 20 |
10001 | 101 | 201 | 4 | 15 | 60 |
10002 | 102 | 202 | 5 | 20 | 100 |
This transaction fact table allows analysis at the transaction level, enabling insights such as top-selling products, customer buying patterns, and revenue per transaction.
A periodic snapshot fact table captures aggregated metrics at specific intervals or time periods, summarizing business activities. It provides a concise overview of performance and trends over time.
Consider a manufacturing company that maintains a periodic snapshot fact table to track monthly production data:
Snapshot date | Total units | Average defects | Total sales |
2023-06-19 | 300 | 0.1 | 1000 |
2023-06-20 | 400 | 0.05 | 1500 |
2023-06-21 | 450 | 0.2 | 2000 |
This snapshot fact table enables analysis of production trends, comparison of defect rates, and identification of potential areas for improvement.
An accumulating snapshot fact table tracks the incremental progress of a specific business process or workflow. It captures significant milestones and associated measures throughout the process.
Consider an e-commerce company with an accumulating snapshot fact table monitoring the order fulfillment process:
Order ID | Order date | Shipping date | Delivery date | Total days |
501 | 2023-06-01 | 2023-06-05 | 2023-06-08 | 7 |
502 | 2023-06-02 | 2023-06-06 | 2023-06-10 | 8 |
503 | 2023-06-03 | 2023-06-07 | 2023-06-13 | 10 |
In the above example, the table tracks the key stages of the order fulfillment process. Each row represents a unique order. The accumulating snapshot fact table allows easy analysis of the order fulfillment process by capturing the dates at each stage. It enables organizations to measure the time taken for each step, monitor the status of orders in real-time, identify bottlenecks, and optimize the overall order fulfillment cycle.
Each type serves a specific purpose in capturing and analyzing different aspects of business data. Organizations can effectively analyze and understand their business data, make informed decisions, and gain valuable insights into various operations by utilizing different types of fact tables.
Free Resources