Forum Discussion
Assistance Required - Power BI Visual Matrix
- 1 year ago
Hi Tejas
Ok, great to hear that there is some progress. I took another look to see if I could get rid of the empty columns . I could only find a solution in Power Query and this was the result :
In general the steps taken are as follows : Identifies the Maxmonth and two months before ( Query : MaxMonthQuery ) , which joins with the Grouped average per assignment group ( Query : GroupedAverageQuery ) . This then finally joins with the MaindataQuery ( filtered to show only 3 months prior to max date of the data ) to merge the average SLA% per group.
For the updated file see the same folder I placed the other Power BI files in.
Hope this helps
Antonio
Hi Lakhani04
I suggest the following :
SLA % 3M =
VAR MaxDate =
CALCULATE(
MAX(Data[Date]),
REMOVEFILTERS(Data)
)
VAR Last3Months =
DATESINPERIOD(
Data[Date],
MaxDate,
-3,
MONTH
)
RETURN
CALCULATE(
AVERAGE(Data[SLA %]),
FILTER(
ALL(Data),
Data[Date] IN Last3Months &&
Data[Assignment Group] = MAX(Data[Assignment Group])
)
)
Result tested with slicer ( table with percentages not affected by slicer - for previous 3 months > as per max date of the data ) :
Below is some further information so that you can adjust the measure if required :
-MaxDate gets the latest date from the entire table, ignoring any filters (like slicers).
-Last3Months creates a list of dates from the last 3 months up to that MaxDate.
-RETURN calculates the average SLA % only for rows in those 3 months and only for the currently selected assignment group.
Hope this helps
Antonio
- Lakhani041 year agoFrequent Visitor
Tried removefilters no luck.
- antfr991 year agoResolver II
Hi Lakhani04
Below is another possible solution without Removefilters :
SLA % Last 3M = VAR MaxDate = CALCULATE( MAX(Data[Date]), ALL(Data) ) VAR Last3Months = DATESINPERIOD( 'Data'[Date], MaxDate, -3, MONTH ) RETURN CALCULATE( AVERAGE('Data'[SLA %]), Last3Months, ALLEXCEPT('Data', 'Data'[Assignment Group]) )with the below result :
Below is my Power BI file if required , feel free to test with a sample of your data.
Power BI Community 25 July 2025
If this amendment does not work , please povide further details ( error message, extra screenshots or a sample file ) .
Antonio
- Lakhani041 year agoFrequent Visitor
Hello Antonio,
Thanks a lot for sharing this file and helping me.
please have look at the below SS when i add 3 month SAL it apperts for all the month I need it as new column in end.
need to show output like below:Groups Jan Feb Mar 3 month SAL Group A 0.87 0.92 0.89 1 Group B 0.91 0.88 0.93 23 Group C 0.95 0.9 0.85 2 Group D 0.86 0.94 0.87 3