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
asl10
Helper I
Helper I

Last Year Total Revenue asOf Today Last Year

Hi,

 

I have the following measure where it returns the diserable result:

 

LYTD asOf Today = CALCULATE([TOTAL REVENUE], DATEADD('Calendar'[Date], -1, YEAR), 'Calendar'[Date] <= TODAY()-335)

 

How can i make the last part (<= TODAY()-335) automatic?

The effect that i would like is to aytomatically find today's date for last year without subtracting the number of days manually.

 

Thank you

1 ACCEPTED SOLUTION
Ssingh
Frequent Visitor

Hi @asl10,

 

Please check the link below, this should help you to get the desired result.

http://community.powerbi.com/t5/DAX-Commands-and-Tips/DAX-YTD-and-PYTD-questions/m-p/116583#M200

 

Thanks,

SSingh

View solution in original post

1 REPLY 1
Ssingh
Frequent Visitor

Hi @asl10,

 

Please check the link below, this should help you to get the desired result.

http://community.powerbi.com/t5/DAX-Commands-and-Tips/DAX-YTD-and-PYTD-questions/m-p/116583#M200

 

Thanks,

SSingh

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

Check out the February 2025 Power BI update to learn about new features.

Feb2025 NL Carousel

Fabric Community Update - February 2025

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