October 28 & 29: Experts share their secrets on how to pass the Fabric Analytics Engineer certification exam—live. Learn more
Solved! Go to Solution.
Hi @Anonymous ,
When using VAR, RETURN is required to return the final value/formula you want. You can write your formula as below
Value =
VAR m =
CALCULATE ( SUM ( 'Table'[A] ), FILTER ( 'Table', 'Table'[B] = "0" ) )
RETURN
m
or simply
Value =
CALCULATE ( SUM ( 'Table'[A] ), FILTER ( 'Table', 'Table'[B] = "0" ) )
By the way in case you are not aware 0 is different from "0" as the latter (in double quotes) is a text string.
Proud to be a Super User!
Hi @Anonymous ,
When using VAR, RETURN is required to return the final value/formula you want. You can write your formula as below
Value =
VAR m =
CALCULATE ( SUM ( 'Table'[A] ), FILTER ( 'Table', 'Table'[B] = "0" ) )
RETURN
m
or simply
Value =
CALCULATE ( SUM ( 'Table'[A] ), FILTER ( 'Table', 'Table'[B] = "0" ) )
By the way in case you are not aware 0 is different from "0" as the latter (in double quotes) is a text string.
Proud to be a Super User!
User | Count |
---|---|
105 | |
99 | |
98 | |
86 | |
49 |
User | Count |
---|---|
162 | |
142 | |
132 | |
102 | |
63 |