Context transition – Model the data

Context transition Another important function of CALCULATE is context transition, which refers to transitioning from row context to filter context. In DAX, there are two evaluation contexts: To review context transition, let’s create a sample table in the data model: On the Home ribbon, select Enter data. Enter Sample in the Name box. Enter the […]

Implement Time Intelligence using DAX – Model the data

Implement Time Intelligence using DAX It is common for business users to want to aggregate metrics—for example, revenue—across time, such as year-to-date revenue for a certain date, or prior-year revenue for the comparable period. Fortunately, DAX has a family of functions, referred to as Time Intelligence, that facilitate such calculations. All Time Intelligence functions require […]

Create semi-additive measures – Model the data

Create semi-additive measures In general, there are three kinds of measures: In this section, we focus on semi-additive measures. There are several ways to write a semi-additive measure, and the correct way for you depends on your business requirements. Let’s say your business is interested in inventory counts, and you have the data model shown […]

Optimize model performance – Model the data

Skill 2.4: Optimize model performance Sometimes after you create the first version of your data model, you may realize that it doesn’t perform well enough. Because of the way Power BI stores data, it may mean that your data model isn’t performing as efficiently as it can. In this section, we review the skills necessary […]

Remove unnecessary columns – Model the data

Remove unnecessary columns Columns in a data model usually serve at least one of two purposes: they could be used to support visuals or calculations, or both. It’s preferable to not load columns that aren’t used for any purpose, especially if they’ve got a high number of distinct values. Some data warehouses include primary keys […]

Summarizing data – Model the data

Summarizing data If your source data provides a level of detail that’s not required by reporting, then you may want to consider summarizing your data to reduce cardinality. For example, if the source data contains daily sales information but you only report monthly values, you may want to summarize your sales data to be at […]