top of page
Antares Studio Games Icon_Small.png

The Antares Alien

Power BI   |  DAX

Writer's pictureBrent Jones

What is the Difference Between FILTER and CALCULATETABLE?

Updated: Jul 19



Expanding on the conversation from this blog written by Arpita Ghosh, How to Differ CALCULATETABLE over FILTER in DAX, I wanted to clearly layout the different combinations you can come across, particularly when used with table variables.


Here I demonstrate 6 ways to look at these:

  1. CalculateTable() with AddColumns() Inside

  2. CalculateTable() with AddColumns() Outside

  3. CalculateTable() with AddColumns() Outside with Calculate()

  4. Filter() with AddColumns() Inside

  5. Filter() with AddColumns() Outside

  6. Filter() with AddColumns() Outside with Calculate()


 

The Alien Says... Do not use #2 or #3. All other methods can be correct depending on your situation, but #2 and #3 just need to be avoided. They return incorrect results as we can see below.




 

- Synopsis -

Method

Results in...

Use or Lose

1) CalculateTable with AddColumns