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
Anonymous
Not applicable

Date column + 30 days

Hi, 

 

I have a date column in a fact table; I am wanting to create a calculated column that will list the date that is 30 days from the date. 

 

How do I do this?

 

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

Hi @Anonymous

create a calculated column that will list the date that is 30 days from the date

if leap year; When month is February; [date] + 29 days; else, when month is february; [date] +28 days

For your requirements, I would suggest as below

create calculated columns

Column = IF(DAY(EOMONTH([date],0))=28,28,IF(DAY(EOMONTH([date],0))=29,29,30))
Column 2 = [date]+IF(DAY(EOMONTH([date],0))=28,28,IF(DAY(EOMONTH([date],0))=29,29,30))

19.png

 

 

Best Regards

Maggie

 

View solution in original post

5 REPLIES 5
v-juanli-msft
Community Support
Community Support

Hi @Anonymous

create a calculated column that will list the date that is 30 days from the date

if leap year; When month is February; [date] + 29 days; else, when month is february; [date] +28 days

For your requirements, I would suggest as below

create calculated columns

Column = IF(DAY(EOMONTH([date],0))=28,28,IF(DAY(EOMONTH([date],0))=29,29,30))
Column 2 = [date]+IF(DAY(EOMONTH([date],0))=28,28,IF(DAY(EOMONTH([date],0))=29,29,30))

19.png

 

 

Best Regards

Maggie

 

Washivale
Resolver V
Resolver V

HI,

 

next date = date + 30 , should work just fine.

 

next date.JPG

Anonymous
Not applicable

Yes is should. Hey Queen, what about February? Just curious. 

Anonymous
Not applicable

hm.  It seems there should be some type of condition placed at som point. Here is my "fake" brainstorming that could possibly develop into a dax equation:

 

if leap year; When month is February; [date] + 29 days; else, when month is february; [date] +28 days

 

Any help?

Hm..
tblDate[Date] + IF( DAY(EOMONTH(tblDate[Date])) = 28, 28, IF( DAY(EOMONTH(tblDate[Date])) = 29, 29, 30))

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!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

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.