Forum Discussion

tbobolz's avatar
tbobolz
Icon for Resolver I rankResolver I
7 years ago
Solved

Creating auto current and prior fiscal year calculation

I'm struggling  to find a solution to creating a calculation that finds the max fiscal year and prior fiscal year, then applies those to a calcultion. I'm a little new to Power BI and would appreciat e any help you could offer.

 

I have this measure that works fine:

Current Fiscal Year Actual = CALCULATE(sum('Gross Revenue by Service Area - FLAT'[Actual]), 'Gross Revenue by Service Area - FLAT'[Fiscal Year - FiscalYear]=2019)
 
I was hoping there's a way to replace the "2019" in the above measure with some that would automatically update each year.
 
I created this measure:
CFY VALUE = max('Gross Revenue by Service Area - FLAT'[Fiscal Year - FiscalYear])
 
Is there a way to convert this measure [CFY VALUE] to a values so that I may insert it into my calculation statement and not have to type in "2019"
 
Thanks for any help you can offer as i learn!
Terry