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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Chris-Mc
Frequent Visitor

New measure - minutes between arrival date time and NOW

hi
I have a direct query where I need to create a measure to find the difference between "adm-date-time" and "Now date time" in minutes
"adm-date-time" is from the diret query and "Now date time" has been created as a measure using NowDateTime = NOW()
I have tried the DATEDIFF function but cannot add the "adm-date-time" to the formula because it is not a measure. 
I have searched through the forums but cant find a solution.  Can anyone assist?
 
ChrisMc_0-1693533541423.png

 

1 ACCEPTED SOLUTION
vicky_
Super User
Super User

I think you're on the right track already, but you'll need to wrap "adm-date-time" in a SELECTEDVALUE() function. In the end, the formula should look like:
Difference = DATEDIFF(SELECTEDVALUE([adm-date-time]), NOW(), MINUTES)

View solution in original post

2 REPLIES 2
vicky_
Super User
Super User

I think you're on the right track already, but you'll need to wrap "adm-date-time" in a SELECTEDVALUE() function. In the end, the formula should look like:
Difference = DATEDIFF(SELECTEDVALUE([adm-date-time]), NOW(), MINUTES)

thanks Vicky.  Such a simple solution. Much appreciated

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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.