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'm working on a Matrix, with multiply values.
And I want to have a Ranking for Value 1, based on it share per Year.
My Problem is, the ranking must ignore all filters.
Attached is the link to the Power-Bi file and the files used.
The example is very simplified. And the final matrix will contain many more values.
But only one Value to Rank.
In my Example Matrix, they are all filters include, that I'm going to use.
https://1drv.ms/u/s!AoFqgLqZH-C0hMlyC4Tfi42fjo_-pg?e=fvB0pq
My Matrix locks like this:
Year | 2020 | 2020 | 2021 | 2021 | 2022 | 2022 |
Value 1 | End of day balance <10 | Value 1 | End of day balance <10 | Value 1 | End of day balance <10 | |
Articel A | 77848,12 | 0 | 61057,88 | 0 | 26475,55 | 0 |
Articel B | 175213,49 | 0 | 127773,10 | 0 | 53784,53 | 0 |
The Matrix I want should look like thsi:
Year | 2020 | 2020 | 2020 | 2021 | 2021 | 2021 | 2022 | 2022 | |
Value 1 | Ranking for Value 1 | End of day balance <10 | Value 1 | Ranking for Value 1 | End of day balance <10 | Value 1 | Ranking for Value 1 | End of day balance <10 | |
Articel A | 77848,12 | 2 | 0 | 61057,88 | 2 | 0 | 26475,55 | 2 | 0 |
Articel B | 175213,49 | 1 | 0 | 127773,10 | 1 | 0 | 53784,53 | 1 | 0 |
Many Thanks in Advance
Solved! Go to Solution.
I will have a look at the file tomorrow morning. Meanwhile, you may try
=
RANKX (
CALCULATETABLE ( '01', ALLEXCEPT ( '01', 'Date'[Year] ) ),
CALCULATE ( SUM ( '01'[Number 1] ) )
)
Hi @Yonah
Not sure if this is what you want. Here is the sample file with the proposed solution https://we.tl/t-fGjyeH6eGx
Test =
IF (
NOT ISBLANK ( SUM ( '01'[Number 1] ) )
&& HASONEVALUE ( '02'[Name] ),
RANKX (
ALLSELECTED ( '02'[Name] ),
CALCULATE ( SUM ( '01'[Number 1] ) )
)
)
Thanks @tamerj1 .
But I try it, and its not working.
That was my DAX.
Just the location of brackets. You may use the same as measure
=
RANKX (
CALCULATETABLE ( '01', ALLEXCEPT ( '01', 'Date'[Year] ) ),
SUM ( '01'[Number 1] )
)
It's working.
But now evrey Articel has the same Rank.
Rank 1.
You can finde the Power BI File here.
https://1drv.ms/u/s!AoFqgLqZH-C0hMlyC4Tfi42fjo_-pg?e=X7jkNv
I will have a look at the file tomorrow morning. Meanwhile, you may try
=
RANKX (
CALCULATETABLE ( '01', ALLEXCEPT ( '01', 'Date'[Year] ) ),
CALCULATE ( SUM ( '01'[Number 1] ) )
)
Hi @Yonah
if you want to ignore all filters then create a calculated column.
RANKX ( CALCULATETABLE (Products, ALLEXCEPT ( Products,Products[Year] ), [Amount] )
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 | |
95 | |
80 | |
68 | |
59 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |