Software & Apps > Apps 330 330 people found this article helpful Facts Vs. Dimensions Tables in a Database Facts and dimensions are key business intelligence terms By Mike Chapple Mike Chapple Twitter Writer University of Idaho Auburn University Notre Dame Former Lifewire writer Mike Chapple is an IT professional with more than 10 years' experience cybersecurity and extensive knowledge of SQL and database management. lifewire's editorial guidelines Updated on June 24, 2021 Reviewed by Jerrick Leger Reviewed by Jerrick Leger Jerrick Leger is a CompTIA-certified IT Specialist with more than 10 years' experience in technical support and IT fields. He is also a systems administrator for an IT firm in Texas serving small businesses. lifewire's editorial guidelines Tweet Share Email Tweet Share Email In This Article Expand Jump to a Section Facts and Fact Tables Fact Table Grain Dimension Tables Relationship of Fact and Dimension Tables Facts and dimensions form the core of any business intelligence effort. These tables contain the basic data used to conduct detailed analyses and derive business value. This article takes a look at the development and use of facts and dimensions in a database. Image Source / Getty Images What Are Facts and Fact Tables? Fact tables contain the data corresponding to a particular business process. Each row represents a single event associated with a process and contains the measurement data associated with that event. For example, a retail organization might have fact tables related to customer purchases, customer service telephone calls, and product returns. The customer purchases table would likely contain information about the amount of the purchase, any discounts applied, and the sales tax paid. The information contained within a fact table is typically numeric data, and it is often data that can be easily manipulated, particularly by summing together many thousands of rows. For example, the retailer described above may want to pull a profit report for a particular store, product line, or customer segment. The retailer can do this by retrieving information from the fact table that relates to those transactions, meeting the specific criteria, and then adding those rows together. What Is a Fact Table Grain? When designing a fact table, developers must pay careful attention to the grain of the table, which is the level of detail contained within the table. The developer designing the purchase fact table for the retail organization described above would need to decide whether the grain of the table is a customer transaction or an individual item purchase. In the case of an individual item purchase grain, each customer transaction would generate multiple fact table entries corresponding to each item purchased. The choice of grain is a fundamental decision made during the design process that can significantly affect the business intelligence effort down the road. What Are Dimensions and Dimension Tables? Dimensions describe the objects involved in a business intelligence effort. While facts correspond to events, dimensions correspond to people, items, or other objects. In the retail scenario used in the example, we discussed that purchases, returns, and calls are facts. On the other hand, customers, employees, items, and stores are dimensions and should be contained in dimension tables. Dimension tables contain details about each instance of an object. For example, the items dimension table would contain a record for each item sold in the store. It might include information such as the cost of the item, the supplier, color, sizes, and similar data. Relationship Between Fact and Dimension Tables Fact tables and dimension tables form a database relationship. Returning to the retail model, the fact table for a customer transaction would likely contain a foreign key reference to the item dimension table, where the entry corresponds to a primary key in that table for a record describing the item purchased. Was this page helpful? Thanks for letting us know! Get the Latest Tech News Delivered Every Day Subscribe Tell us why! Other Not enough details Hard to understand Submit