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
PowerBINoob24
Resolver I
Resolver I

Finding difference in minutes between two date/time fields

If got a column that I'm trying to calculate the number of minutes between to date/time fields.  I've currently got 

Time To Access = DATEDIFF('UniqueUsers'[First Access Time],'UniqueUsers'[Send Date].[Day],MINUTE).  The Time to Access Column is formatted at a whole number data type and returns values like -64561883 for a time date that is 19 minutes apart.
 
Any thoughts on what I am doing wrong?
1 ACCEPTED SOLUTION
grandtotal
Resolver III
Resolver III

Make sure that both input columns are in datatime format.
Then try to remove the .[Day] part:

Time To Access = DATEDIFF('UniqueUsers'[First Access Time],'UniqueUsers'[Send Date],MINUTE)

 

View solution in original post

2 REPLIES 2
grandtotal
Resolver III
Resolver III

Make sure that both input columns are in datatime format.
Then try to remove the .[Day] part:

Time To Access = DATEDIFF('UniqueUsers'[First Access Time],'UniqueUsers'[Send Date],MINUTE)

 

That was it....just ahd to remove the .DAY  Thanks!  It's the little things.....

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.