Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello,
I'm trying to set up a new measure to calculate number of days between two date fields in the same table. I've tried using the DATESBETWEEN DAX function but it doesn't work for me.
The start date field is called Close Date and the end date is called Let Date. They're both in a table called CBLShortlists. I've tried the following but it doesn't recognise the field names:
Solved! Go to Solution.
This is the way. You can just subtract days (i.e. LetDate - CloseDate) since they are stored as the number of days since 12/30/1899 but DATEDIFF is more flexible and can easily handle other units too (SECOND, MINUTE, HOUR, DAY, WEEK, MONTH, QUARTER, YEAR).
@g_hill The DATESBETWEEN function is for Time Intelligence and returns a table of date values between two dates rather than a single number. It's generally used for filtering.
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
23 | |
8 | |
7 | |
6 | |
6 |
User | Count |
---|---|
28 | |
11 | |
11 | |
10 | |
6 |