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

Data Days is here! Join us now for 60+ days of learning, challenges, and connection. Learn more

Reply
akshaysmath
Frequent Visitor

Get last date on next year February

Hey guys,

 

Can anybody help me with the below concern?

 

I'm looking to get the last date of next year February month. For example, if the current year is 2022, I want next year's February end date, which is 28-02-2023. I'm trying to get it with the below DAX command but the value is populating "Blank" when I pull it in a card.

 

Financial Year End =
    var get_current_Year = STARTOFYEAR(ENDOFYEAR('YTD data'[part_date_3]))
    var get_feb_last_date = DATEADD(DATEADD(DATEADD(get_current_Year , 2, MONTH),-1,DAY),1,YEAR)
    return get_feb_last_date
 
Appreciate the help.
1 ACCEPTED SOLUTION
Anonymous
Not applicable

Try this you should have the value :

nextclosingdate=

var nextyear=year(today())+1

var datemaxmarch=date(nextyear,3,1)

return

datemaxmarch-1

 

but the much simple would be to create the dfate on your date table with calendar function

 

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Try this you should have the value :

nextclosingdate=

var nextyear=year(today())+1

var datemaxmarch=date(nextyear,3,1)

return

datemaxmarch-1

 

but the much simple would be to create the dfate on your date table with calendar function

 

Anonymous
Not applicable

i

 

If you have a date table with dates up to end of feb 2023just do this :

nextclosingdate=

var nextyear=year(today())+1

return

calculate(max(Date[date],Date[Year]=nextyear&&Month=2)

Hi JamesFr06,

 

Thanks for your quick response. I don't have dates going till Feb 2023. Reason why I'm getting a blank value in the card. Is there a way where I can get the result without depending on any column? 

Helpful resources

Announcements
Fabric Data Days is here Carousel

Fabric Data Days 2026

Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.

May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 2026 Power BI update to learn about new features.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.