05.2Measure, column or table: which one to choose?

Measure, calculated column, calculated table. When you face a new calculation, one or two questions are enough to choose.

05.2.1Two questions to ask yourself

Should the result change when the report is filtered?

  • Yes. It is a measure. Revenue, an average or the share of New York are figures to read in a visual, and they follow the filters.
  • No. Move on to the second question.

Is it a piece of information on each row, or a whole table?

  • A piece of information on each row. It is a calculated column. The amount of each sale, for example.
  • A whole table. It is a calculated table. The list of the customers in New York, for example.

05.2.2When in doubt, a measure

A calculated column keeps a value on each row. On a table of millions of rows, it takes up space in the file. A measure keeps nothing. Power BI calculates it only for what the visual shows.

When both are possible, prefer the measure. The rest of the course mostly writes measures.

Quiz

The questions often rely on the course tables. Keep them in view in their floating window, which you can move and enlarge.

Question 1

On each sale, you want a “Big sale” label if the amount is over 150,000. It must not change with the filters. What do you create?

Question 2

Your manager wants to read, in a table by city, the share of each city in the revenue. It must follow the “Year” slicer placed on the page. What do you create?

Question 3

You want to see, in the Data pane, a separate table with only the customers in Chicago and all their columns. It must not change with the filters. What do you create?

Key takeaways
  • A result that follows the filters of the report is calculated with a measure.
  • A fixed piece of information on each row is calculated with a calculated column, a whole table with a calculated table.
  • When in doubt, prefer the measure.