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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
ss89
Helper II
Helper II

Add Integer Column to Date Column

Hello Community,

 

I am trying to add an integer column and a date column (DATE_IN ) to get arrive a new column called Due Date.

Which formula can I use in Power BI?

 

ss89_0-1673885993373.png

 

Thanks in advance for your support! 

 

 

 

 

1 ACCEPTED SOLUTION
Greg_Deckler
Super User
Super User

@ss89 Just use + operator like [Date] + [Some Integer Column]. 

 

DAX Dates are decimal numbers where the integer portion is the number of days since December 30th, 1899 and the decimal portion is fractions of a day, like 1/24/60/60. So, just adding an integer to a date adds that many days to the date.


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

2 REPLIES 2
FreemanZ
Super User
Super User

hi @ss89 

As suggested by Greg, you can try to add a column like:

DueDate = [DATE_IN] + LOOKUPVALUE(...)

Greg_Deckler
Super User
Super User

@ss89 Just use + operator like [Date] + [Some Integer Column]. 

 

DAX Dates are decimal numbers where the integer portion is the number of days since December 30th, 1899 and the decimal portion is fractions of a day, like 1/24/60/60. So, just adding an integer to a date adds that many days to the date.


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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