You are a data analyst at a retail company. You are building a Power BI report to analyze sales performance across multiple stores. The source data comes from an Azure SQL Database that contains a table 'Sales' with columns: StoreID, ProductID, SaleDate, Quantity, and Amount. The database also has a 'Stores' table with StoreID and StoreName, and a 'Products' table with ProductID, ProductName, and Category. You need to create a data model that supports filtering by store, product category, and date, and also allows calculation of year-over-year sales growth. You want to minimize the model size and ensure optimal performance. The data volume is large (millions of rows). You must design the data model. What should you do?
Creating a star schema by importing Sales as a fact table along with Stores, Products, and a separate date table generated via CALENDAR is the optimal design. The date table must be marked as a date table in Power BI to enable time-intelligence functions like TOTALYTD and SAMEPERIODLASTYEAR to work predictably across fiscal and calendar periods. Relationships between Sales and the dimension tables filter facts efficiently, reduce model size through dimension normalization, and improve DAX query performance, making this the correct approach.
Why this answer
It follows the star schema best practice: importing dimension tables (Stores, Products, a dedicated Date table) and the fact table (Sales) separately, then creating relationships. This minimizes model size by avoiding data duplication and enables efficient filtering by store, product category, and date. The separate date table is essential for accurate year-over-year calculations using DAX time intelligence functions like SAMEPERIODLASTYEAR, which require a continuous date range.
Exam trap
The trap here is that candidates often choose Option A (flat table) thinking it simplifies the model, not realizing that star schema design is essential for performance and compression in large datasets, and that Power BI's query folding can handle joins efficiently without merging.
How to eliminate wrong answers
Option A is wrong because merging all tables into a single flat table in Power Query creates massive data duplication (repeating StoreName and ProductName for every sales row), drastically increasing model size and degrading performance with millions of rows. Option C is wrong because importing only the Sales table and using calculated columns with RELATED forces Power BI to store the dimension data within the fact table, bloating the model and losing the benefits of separate dimension tables for filtering and compression. Option D is wrong because relying on the auto date/time feature creates hidden, auto-generated date tables that are not customizable, cannot support proper year-over-year calculations with DAX time intelligence, and can increase model size unnecessarily for large datasets.