Forum Discussion
nick1097
2 years agoFrequent Visitor
CALCULATE function result changes by using slicer
Hello all, I hope you can help, I think it is just a matter of understanding the filter in CALCULATE. I am currently using a calculate function and I can“t explain the result myself. For example...
- 2 years ago
I found the problem. The value was influenced by the date-slicer, that was referencing the date column of the fact table. Since I created a date dimension table and changed the reference of the slicer, it works with only a CALCULATE function!
Gabry
2 years agoSuper User
Already tried this?
Process Time B =
CALCULATE(
AVERAGE(
TableX[Process Time]
),
All(TableX[Product]),
TableX[Product] = "B"
)
Do you really have performance issue using filter or it's just speculation?
As i know every filter put in the calculate functions it gets converted behind the scenes in a filter so
nick1097
2 years agoFrequent Visitor
First of all, thank you for your time and help!
I tried this already. With that it shows the same values like the original code:
Process Time B =
CALCULATE(
AVERAGE(
TableX[Process Time]
),
TableX[Product] = "B"
)