Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredJoin 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.
Hi,
I have a requirement to fill the missing values of the months with the average of previous months with in fiscal year,
Note: My fiscal year starts from Oct so the average should be calculated form oct of that year.
Can some one help me to achieve this. Thanks in advance.
Solved! Go to Solution.
Hi @Reddy5833 ,
Please create two calculated columns:
Year =
VAR _start_of_year =
STARTOFYEAR ( 'Date'[Date], "9/30" )
VAR _fin_year =
YEAR ( _start_of_year )
RETURN
_fin_yearColumn =
VAR _avg =
CALCULATE (
AVERAGE ( 'Table'[Value] ),
FILTER (
'Table',
'Table'[Category] = EARLIER ( 'Table'[Category] )
&& 'Table'[Year] = EARLIER ( 'Table'[Year] )
)
)
VAR _fill =
IF ( 'Table'[Value] <> BLANK (), 'Table'[Value], _avg )
RETURN
_fill
Result:
The PBIX file is attached for reference.
Best Regards,
Gao
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data
Hi @Anonymous
Thanks a lot, it is working like a charm.
Hi @Reddy5833 ,
Please create two calculated columns:
Year =
VAR _start_of_year =
STARTOFYEAR ( 'Date'[Date], "9/30" )
VAR _fin_year =
YEAR ( _start_of_year )
RETURN
_fin_yearColumn =
VAR _avg =
CALCULATE (
AVERAGE ( 'Table'[Value] ),
FILTER (
'Table',
'Table'[Category] = EARLIER ( 'Table'[Category] )
&& 'Table'[Year] = EARLIER ( 'Table'[Year] )
)
)
VAR _fill =
IF ( 'Table'[Value] <> BLANK (), 'Table'[Value], _avg )
RETURN
_fill
Result:
The PBIX file is attached for reference.
Best Regards,
Gao
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 79 | |
| 48 | |
| 35 | |
| 31 | |
| 27 |