Dashboard Mode - Optimizing DAX queries
Goal
Understand how to write efficient DAX formulas to improve Power BI report performance.
Understand how to write efficient DAX formulas to improve Power BI report performance.
| OrderID | Product | Category | Quantity | UnitPrice | OrderDate |
|---|---|---|---|---|---|
| 1001 | Notebook | Stationery | 5 | 2.5 | 2024-01-10 |
| 1002 | Pen | Stationery | 10 | 1.2 | 2024-01-11 |
| 1003 | Chair | Furniture | 2 | 45 | 2024-01-12 |
| 1004 | Desk | Furniture | 1 | 120 | 2024-01-13 |
| 1005 | Marker | Stationery | 7 | 1.5 | 2024-01-14 |
| 1006 | Bookcase | Furniture | 1 | 80 | 2024-01-15 |
Total Sales = SUMX(Sales, Sales[Quantity] * Sales[UnitPrice])Total Quantity = SUM(Sales[Quantity])Sales by Category = SUMX(FILTER(Sales, Sales[Category] = SELECTEDVALUE(Sales[Category])), Sales[Quantity] * Sales[UnitPrice])Total Sale = Sales[Quantity] * Sales[UnitPrice]Total Sales Optimized = SUMX(Sales, Sales[Quantity] * Sales[UnitPrice])+----------------------+----------------------+ | Total Sales | Total Quantity Sold | | (KPI) | (KPI) | +----------------------+----------------------+ | | | Sales by Category (Bar Chart) | | | +----------------------------------------------+ | | | Sales Details (Table) | | | +----------------------------------------------+
Adding a slicer for Category filters all components:
This interactivity helps users focus on specific product categories and see optimized DAX measures update instantly.
If you add a filter for Category = Furniture, which components update and what are their new values?