Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi,
i have a trivial question but i dont can solve this issue .
So i have this Measure, a static string/text "2018", get the result and works fine. 😉
But now i want to replace the static stuff to dynamic measure "LastYear" and get this issue:
When i show both Measure "LastYear and ActualYear" in a card, table,.. then it show me the correct result "2018" & "2019"
I hope you can help me and thanks in advance
Kind regards,
Unknown
Solved! Go to Solution.
@Anonymous -
Try it with a variable instead of a measure.
Variables can be loaded with a value and that value can then be used.
Measures are evaluated at the point in which they are used. So in your measure, there is probably something else affecting it.
General variable usage:
Previous Year = var my_variable = max('Date'[Year]) return my_variable - 1
Cheers!
Nathan
Hi @Anonymous
It looks like you are using the simplified syntax for the filter parmeters in the CALCULATE where it is not allowed.
Instead of
CALCULATE(SUM( ...); Table1[Geschäftsjahr] = [LastYear])
try
CALCULATE( SUM( ...);
FILTER( ALL(Table1[Gefächstjahr]); Table1[Geschäftsjahr] = [LastYear]) )
@Anonymous -
Try it with a variable instead of a measure.
Variables can be loaded with a value and that value can then be used.
Measures are evaluated at the point in which they are used. So in your measure, there is probably something else affecting it.
General variable usage:
Previous Year = var my_variable = max('Date'[Year]) return my_variable - 1
Cheers!
Nathan
Hi @Anonymous
It looks like you are using the simplified syntax for the filter parmeters in the CALCULATE where it is not allowed.
Instead of
CALCULATE(SUM( ...); Table1[Geschäftsjahr] = [LastYear])
try
CALCULATE( SUM( ...);
FILTER( ALL(Table1[Gefächstjahr]); Table1[Geschäftsjahr] = [LastYear]) )
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
111 | |
100 | |
80 | |
64 | |
58 |
User | Count |
---|---|
148 | |
111 | |
93 | |
84 | |
66 |