Factless fact table

A factless fact table is a fact table that does not have any measures.  It is essentially an intersection of dimensions (it contains nothing but dimensional keys).

There are two types of factless tables:  One is for capturing an event, and one is for describing conditions.

An event establishes the relationship among the dimension members from various dimensions, but there is no measured value.  The existence of the relationship itself is the fact.

This type of fact table itself can be used to generate useful reports.  You can count the number of occurrences with various criteria.  For example, you can have a factless fact table to capture student attendance, creating a row each time a student attends a class.  The following questions can be answered:

  • Which class has the least attendance?
  • Which teachers taught the most students?
  • What is the average number of attendance of a given course?

All the queries are based on the COUNT() with the GROUP BY queries.  The interesting metrics are the nested GROUP BY so you can first count and then apply other aggregate functions such as AVERAGE, MAX, MIX.

The other type of factless table is for describing conditions and is called a “coverage table” by Ralph Kimball.  It is used to support negative analysis reports.  For example, a store that did not sell a product for a given period.  To produce such a report, you need to have a factless fact table to capture all the possible combinations of products that were on sale.  You can then figure out what is missing by comparing the factless table with the sales table for the list of products that did sell.

As another example, say an investment bank assigns a broker to each customer.  Each row in this factless fact table represents a bounded time period during which a broker was assigned to a particular customer.  This factless fact table can be compared to one that tracks investment transactions to find brokers who are not interacting with their customers, brokers who conducted transactions with accounts that belong to a different broker, etc.

More info:

Factless Fact Tables by Ralph Kimball

Factless Fact Tables by Chris Adamson

Data Warehouse Design Considerations

About James Serra

James is a big data and data warehousing solution architect at Microsoft. Previously he was an independent consultant working as a Data Warehouse/Business Intelligence architect and developer. He is a prior SQL Server MVP with over 25 years of IT experience.
This entry was posted in SQLServerPedia Syndication, SSAS. Bookmark the permalink.

3 Responses to Factless fact table

  1. Sreehari says:

    Hi,

    Can you please give with an example model where it has fact,factless fact and dimesion. And the also the relationship between the three. As per i understood was, Between Dimesion and fact it has Many to Many relationship. Same way to resolve the Many to Many relationship between Fact and dimension we use Factlessfact.

  2. Pingback: Preparation for the 70-467 SQL BI exam | x86x64

  3. Geoff Johnson says:

    I’m having trouble using factless fact tables (FFTs) in Power BI. Because I am using values from two dimensions related via a FFT, but I am not actually using any values in the FFT per se. Power BI does not appear to be enforcing any relationship between dimensions unless the visualization includes some value from the fact table in between them. Under some circumstances I could perhaps use a “counter” value from the FFT, but in this case I need to do _distinct_ counts on the operational DB key values from one of the dimensions. I have considered using the “merge query” tool to bring the data from both dimensions into one query result, but the numbers of columns and rows are so large that the process didn’t even finish before I abandoned it as a viable option. Do you have any suggestions?

Leave a Reply

Your email address will not be published. Required fields are marked *