Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
ovonel
Post Prodigy
Post Prodigy

How to achieve a full year, last year measure?

I need to achieve a FULL Year measure for Last Year.

 

To achieve that, I have to… Ignore the Month and Date filters, and somehow pick the ‘Fiscal Year’ selected value and do a -1 to it.

 

My filters:

ovonel_0-1650634184125.png

 

 

For Full Year what I have is:

Sales Full Year:=



CALCULATE

([Sales] , ALL('Date'[FY & Month], 'Date'[Week Offset],'Date'[Date]))

 

This works fine!

 

 

 

But for Full Year Last Year I am doing this:

 

Sales Full Year LY:=

CALCULATE ( [Sales Full Year] , PARALLELPERIOD ( 'Date'[Date] , -12 , MONTH ) )

 

 

But it doesn’t work! How can I achieve my goal?

 

1 ACCEPTED SOLUTION
v-yanjiang-msft
Community Support
Community Support

Hi @ovonel ,

According to your description, I create a sample.

Actually the PARALLELPERIOD can get the correct date period, but it can still be affected by the slicer, so it return blank.

vkalyjmsft_0-1651132008645.png

Modify the formula to:

Sales Full Year LY =
CALCULATE (
    [Sales Full Year],
    PARALLELPERIOD ( 'Date'[Date], -12, MONTH ),
    ALL ( 'Date' )
)

Get the correct result.

vkalyjmsft_1-1651132349551.png

I attach my sample below for reference.

 

Best Regards,
Community Support Team _ kalyj

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

 

View solution in original post

2 REPLIES 2
v-yanjiang-msft
Community Support
Community Support

Hi @ovonel ,

According to your description, I create a sample.

Actually the PARALLELPERIOD can get the correct date period, but it can still be affected by the slicer, so it return blank.

vkalyjmsft_0-1651132008645.png

Modify the formula to:

Sales Full Year LY =
CALCULATE (
    [Sales Full Year],
    PARALLELPERIOD ( 'Date'[Date], -12, MONTH ),
    ALL ( 'Date' )
)

Get the correct result.

vkalyjmsft_1-1651132349551.png

I attach my sample below for reference.

 

Best Regards,
Community Support Team _ kalyj

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

 

Whitewater100
Solution Sage
Solution Sage

Hi:

Can this work? Example set up measures.

Sales = SUM(Sales[Sales Amt])

Sales Full Year = CALCULATE([Sales], FILTER(Dates, Dates[Year] = XXXX))  * you can choose the year, e.g. 2021

 

Sales Full Year LY:=

CALCULATE ( [Sales Full Year] , PARALLELPERIOD ( 'Date'[Date] , -1 , YEAR ) )

 

If you want to see a better over view, please see page 3 on the attached file. Here you can use the fields from the Date Table to also show you yearly sales. I hope this helps!

https://drive.google.com/file/d/1gHqCvtbQf3NeoFcVak_EF45cjH2kAiF8/view?usp=sharing 

 

Helpful resources

Announcements
Feb2025 Sticker Challenge

Join our Community Sticker Challenge 2025

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

Jan NL Carousel

Fabric Community Update - January 2025

Find out what's new and trending in the Fabric community.