I have a table called dbo.employees, I run some queries and I get the below result.
empId | timeIn | timeOut | timeDiff
------+----------+----------+------------
1001 | 03:49:54 | 15:43:42 |
1017 | 06:27:10 | 13:47:40 |
1005 | 05:49:50 | 13:42:03 |
I'd like to run an extra query to work out the timeDiff so that it turns out like the below. I'm thinking the TIMEDIFF function could do this? I'd like to calculate it in hours/minutes if possible.
empId | timeIn | timeOut | timeDiff
------+----------+----------+------------
1001 | 03:49:54 | 15:43:42 | 11hr, 53min
1017 | 06:27:10 | 13:47:40 | 8hr, 20min
1005 | 05:49:50 | 13:42:03 | 7hr, 52min
Thank you very much in advance.