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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Neandril
Frequent Visitor

Get the second tuesday of the next Month from today

Hello.

 

I want to retrieve the next second tuesday of the next month from today. How can I achieve this in DAX please ?

For example, next 2nd tuesday is the 14th on February.

 

Thank's in advance

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Neandril ,

 

Here I suggest you to try this code to create a calculated column or a measure.

New =
VAR _NextMonthFirstDay =
    EOMONTH ( TODAY (), 0 ) + 1
VAR _WeekdayOfFirstDay =
    WEEKDAY ( _NextMonthFirstDay, 2 )
RETURN
    IF (
        _WeekdayOfFirstDay > 2,
        _NextMonthFirstDay - _WeekdayOfFirstDay + 16,
        _NextMonthFirstDay - _WeekdayOfFirstDay + 9
    )

Here I have a test on a Date table, it works.

RicoZhou_0-1673848753877.png

 

Best Regards,
Rico Zhou

 

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

3 REPLIES 3
amitchandak
Super User
Super User

@Neandril , Create a new column or measure as per need

 

New =var _nx = EOMONTH(TODAY(),0)+1
return _nx -WEEKDAY(_nx,2) +16
Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Thank's for this.

However, it "partially" works. On some months, it returns incorrect values (I created a calendar table for test purpose). Last November, it should be the 8th, but this formula returns the 15th.

 

Anonymous
Not applicable

Hi @Neandril ,

 

Here I suggest you to try this code to create a calculated column or a measure.

New =
VAR _NextMonthFirstDay =
    EOMONTH ( TODAY (), 0 ) + 1
VAR _WeekdayOfFirstDay =
    WEEKDAY ( _NextMonthFirstDay, 2 )
RETURN
    IF (
        _WeekdayOfFirstDay > 2,
        _NextMonthFirstDay - _WeekdayOfFirstDay + 16,
        _NextMonthFirstDay - _WeekdayOfFirstDay + 9
    )

Here I have a test on a Date table, it works.

RicoZhou_0-1673848753877.png

 

Best Regards,
Rico Zhou

 

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

 

 

 

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.