The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
After being berated on stack overflow I though I'd try my question here. I have a dashboard for attendance at a school district. My source data is the following query:
This is a large query made up of 2m+ rows, it is each non null value in our attendance table. This includes "Periods" All day, P0, P1, P2,..., P9. I made a Matrix that summarizes this data:
Under my Attendance Filters I have a "between" slicer labeled "Test", this is a calculated column from a summary table:
Summary Table = SUMMARIZE('Period Attendance','Period Attendance'[Student ID], "Period Count", COUNT('Period Attendance'[Attendance Code]),"test", COUNTROWS(VALUES('Period Attendance'[Attendance Code])))
However, this is static. I have row level security for users district wide, and the min max does not change with and slicer or filter.
Lastly, here are my connections, it's very messy but I want to give as much info as possible:
Desired Result: I want to have a dynamic min max slicer that can set a limit for the matrix row subtotals. If I filter the school and attendance codes, I want the min and max to change with the matrix.
Did you ever find a solution for this? I am trying to solve the same problem, want to filter the subtotals but maintain context from other slicers.
Update for anyone who may run into this issue in the future, I have found a solution:
Create a parameter through Modeling -> New Parameter. It seems there is a bug in Power Bi where the parameter slicer value will change on it's own if you have more than ~1000 values, workaround for this is change it from "Greater than or Equal to" to "Between" in slicer settings. This seems to fix it.
In the parameter Measure, change the one to Min(parameter) and create another for Max(parameter). By default it is SELECTEDVALUE(parameter)
Create a new measure, mine is
@Anonymous I'm not fully understanding "set a limit for the matrix row subtotals", can you explain that? Are you looking for a "selection" measure or you want the subtotals to actually cap out at certain values? If either of those are the case, these might help:
The Complex Selector - Microsoft Fabric Community
Matrix Measure Total Triple Threat Rock & Roll - Microsoft Fabric Community
@Greg_Deckler Here's an example, I have my matrix showing every attendance code for every student. I want to see students who have between 10 and 15 attendance codes for code A. I'm trying to figure out the code that can set the upper and lower limit for the matrix subtotal by row.
The way I'm trying to do this is by creating a dynamic column that counts rows based on what i'm filtering, then putting that column into a between slicer.