March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hello All
Is there a way to calculate the Number of Nights between two dates?
If so, please suggest a way to do it as a calculated column & through the measure.
Many thanks
Gaurav
Solved! Go to Solution.
Hi @gauravnarchal ,
I create some data:
Here are the steps you can follow:
1. Create calculated column.
day_number = DATEDIFF('Table'[Start date],'Table'[End date],DAY)
2. Result:
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @gauravnarchal ,
I create some data:
Here are the steps you can follow:
1. Create calculated column.
day_number = DATEDIFF('Table'[Start date],'Table'[End date],DAY)
2. Result:
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
"Days Between = DATESBETWEEN ( 'Table' [Dates], 'Table' [Start Date], 'Table [End Date] ) This will return a single number for the number of days between the two dates."
@gauravnarchal
What is the night definition you would use? I mean the time frame
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
124 | |
89 | |
84 | |
70 | |
51 |
User | Count |
---|---|
206 | |
146 | |
97 | |
79 | |
69 |