Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
I have 2 table dates and Transactions
date table has data (all days and months)
| Year | MOnth | date | ReportYear |
| 2018 | jan | 01/01/2018 | Previous year |
| 2018 | jan | 02/01/2018 | Previous year |
| 2018 | feb | Previous Year | |
| 2019 | Jan | Current Year | |
| 2019 | feb | Current Year |
Now I have transaction Table
| Year | Stream | Hour |
| 2018 | a | 10 |
| 2018 | a | 20 |
| 2019 | a | 30 |
| 2019 | a | 40 |
Both the table are joined on Year column
Now i have 2 slicer
and a table which shows
| Stream | total Hours |
| a |
When multiple FYs is selected:
|
Hi @Anonymous - Please try to create the below measures: if the issue is not closed.
reference link:
Solved: calculate average based on academic year - Microsoft Fabric Community
Try below measures:
// Measure for Total Hours in the Current Year
TotalHoursCurrentYear =
CALCULATE(
SUM(Transactions[Hour]),
FILTER('Date', 'Date'[ReportYear] = "Current Year")
)
// Measure for Total Hours in the Previous Year
TotalHoursPreviousYear =
CALCULATE(
SUM(Transactions[Hour]),
FILTER('Date', 'Date'[ReportYear] = "Previous Year")
)
// Measure for Monthly Average Hours in the Current Year
MonthlyAverageHoursCurrentYear =
DIVIDE([TotalHoursCurrentYear], 12)
// Measure for Monthly Average Hours in the Previous Year
MonthlyAverageHoursPreviousYear =
DIVIDE([TotalHoursPreviousYear], 12)
// Measure for Selected Months
SelectedMonths =
COUNTROWS(
VALUES('Date'[Month])
)
// Measure for Total Selected Hours
TotalSelectedHours =
DIVIDE([TotalHoursPreviousYear], 12) * [SelectedMonths] +
DIVIDE([TotalHoursCurrentYear], 12) * [SelectedMonths]
// Measure for Display in the Table
DisplayTotalHours =
SUMX(
VALUES(Transactions[Stream]),
[TotalSelectedHours]
)
Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!
Proud to be a Super User! | |
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
Check out the November 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 65 | |
| 46 | |
| 43 | |
| 26 | |
| 19 |
| User | Count |
|---|---|
| 198 | |
| 126 | |
| 102 | |
| 69 | |
| 53 |