11.6What each function puts in its table

ALL and ALLSELECTED produce a table, as you have seen. VALUES produces one too, the visible values of a column. On the same row of a visual, these three tables still do not hold the same content. This content decides the result of your formulas, and this lesson compares it, then puts it to the test in CALCULATE.

11.6.1Three tables for the same row

Take a visual by city, with a slicer that keeps only New York and Chicago. Let’s stand on the New York row.

City

Chicago

New York

Toronto

Table visual, The revenue by city, with a slicer
CityRevenue
Chicago500,000
New York900,000
Total1,400,000

This is a reproduction of the Power BI interface for teaching purposes. It differs from the real interface.

On this row, here is what the table of each function contains:

  • ALL( Customers[City] ) produces New York, Chicago and Toronto. Neither the slicer nor the row changes anything.
  • ALLSELECTED( Customers[City] ) produces New York and Chicago, the cities picked in the slicer.
  • VALUES( Customers[City] ) produces New York, the only city visible on the row.

The three functions read the same column. What sets them apart is the filters each one takes into account. ALL takes no filter into account. ALLSELECTED takes the slicer into account, not the row. VALUES takes everything into account, the slicer as well as the row.

The rest of this lesson is part of izyDAX Pro

You have just read the first section. The next 4, their animations, the exercises and the summary are waiting for you with izyDAX Pro, in a single payment.