DAX as a calculated column or measure
After creating our data model, we need to calculate some key numbers to track performance. There are some basic calculations we can create from the columns with values in our data model, using functions such as SUM
, AVERAGE
, MAX
, MIN
, and so on.
For example, we can find the total quantity of products sold by summing all the values in the Quantity column of our Main Transaction table.
There are measures we can create by simply dragging existing columns or fields to the Values section of a PivotTable. These measures are called implicit measures, while the ones we create with formulas that can be accessed and reused in any part of our data model are called explicit measures. Explicit measures can be created using DAX. DAX is the formula language of a data model. In the data model, we can create two types of DAX calculations: calculated columns and measures.
In an earlier chapter, we learned how to create calculated columns. In this chapter...