cancel
Showing results for 
Search instead for 
Did you mean: 

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Reply
CJKPowerBI
Helper I
Helper I

date, forumal to get the 02nd day of each month when is at the current month... e.g 11/02/22

hello,

 

i was wondering if anyone knows a formula to always get the 02nd day of the current month...

 

that would be 11/02/22 and when deember comes then it would change to 12/02/22

 

thank you

2 ACCEPTED SOLUTIONS
AllisonKennedy
Super User
Super User

2nd of Month = EOMONTH( TODAY(), -1) + 2


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

View solution in original post

 

@CJKPowerBI 

 

2nd of Month adjusted = 
IF(
    DAY(TODAY())>10,
    EOMONTH(TODAY(),0)+2,
    EOMONTH(TODAY(),-1)+2
)

 

Kudos @AllisonKennedy : I dod not know the EOMONTH() function. Thank you!

 

Best regards

Michael

-----------------------------------------------------

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

@ me in replies or I'll lose your thread.

 

------------------------------------------------------------------
Visit my blog datenhungrig which I recently started with content about business intelligence and Power BI in German and English or follow me on LinkedIn!

View solution in original post

4 REPLIES 4
AllisonKennedy
Super User
Super User

2nd of Month = EOMONTH( TODAY(), -1) + 2


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

thank you @AllisonKennedy  that worked but i was wonderning and i should have said it before if:

 

- if today is more than the 10th of this month then to bring the 02nd of the next month otherwise the 02nd of this month...

 

let me know pls.

 

@CJKPowerBI 

 

2nd of Month adjusted = 
IF(
    DAY(TODAY())>10,
    EOMONTH(TODAY(),0)+2,
    EOMONTH(TODAY(),-1)+2
)

 

Kudos @AllisonKennedy : I dod not know the EOMONTH() function. Thank you!

 

Best regards

Michael

-----------------------------------------------------

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

@ me in replies or I'll lose your thread.

 

------------------------------------------------------------------
Visit my blog datenhungrig which I recently started with content about business intelligence and Power BI in German and English or follow me on LinkedIn!

thank you @Mikelytics  and thank you @AllisonKennedy ... both worked great

Helpful resources

Announcements
PBI November 2023 Update Carousel

Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

Community News

Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

Dashboard in a day with date

Exclusive opportunity for Women!

Join us for a free, hands-on Microsoft workshop led by women trainers for women where you will learn how to build a Dashboard in a Day!

Power BI Fabric Summit Carousel

The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors