Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
Hi All,
I would like to create a matrix where one measure will be displayed only for one row [name], so I have 4 different measures in 4 rows:
Matrix
Dates.... | |
Row for Name A | Values for Measure 1 |
Row for Name B | Values for Measure 2 |
Row for Name C | Values for Measure 3 |
Row for Name D | Values for Measure 4 |
I am able to do it with SWITCH() and SELECTEDVALUE() functions, but it does not work exactly as I want it to.
When I put TRUE() as first argument in SWITCH() function, it only shows 2 rows and when I change it to FALSE() it shows to other rows.
Here is a formula I use:
Selected ES code =
SWITCH(
TRUE(),
SELECTEDVALUE('Table1'[NamesColumn]) == "Name A", [Measure 1],
SELECTEDVALUE('Table1'[NamesColumn]) == "Name B", [Measure 2],
SELECTEDVALUE('Table1'[NamesColumn]) == "Name C", [Measure 3],
SELECTEDVALUE('Table1'[NamesColumn) == "Name D", [Measure 2],
BLANK()
)
Can anybody help?
@tomaszes19 , Assuming Namescolumn is used in visual
try like
Selected ES code =
Sumx(Values('Table1'[NamesColumn), calculate(
SWITCH(
TRUE(),
max('Table1'[NamesColumn]) = "Name A", [Measure 1],
max('Table1'[NamesColumn]) = "Name B", [Measure 2],
max('Table1'[NamesColumn]) = "Name C", [Measure 3],
max('Table1'[NamesColumn) = "Name D", [Measure 2],
BLANK()
) ))
It turned out I made a mistake in the called measures... Sorry and thank you for your time!
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
104 | |
69 | |
48 | |
41 | |
34 |
User | Count |
---|---|
164 | |
111 | |
62 | |
53 | |
38 |