Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!
How to calculate the date difference between 2 date columns in Direct query? I tried DateDiff function, but this is not supporting in Direct Query mode
None of the above options work. I always get the "not supported in directquery mode" message.
Are there any other ways of addressing this Date Difference issue in Direct Query?
Hey,
You can try using ([Date A]-[Date B])*24.
@Karthikreddy523 Try:
( [Date 1] - [Date 2] ) * 1.
I tried it,but the results are not accurate and i need the difference in years.Please find the screenshot here
| User | Count |
|---|---|
| 56 | |
| 41 | |
| 38 | |
| 21 | |
| 21 |
| User | Count |
|---|---|
| 140 | |
| 102 | |
| 64 | |
| 36 | |
| 35 |