Synopsis
TIMEDIFF(expr1
, expr2
)
Returns the difference between expr1
and expr2
(expr1
- expr2
) as a time value. Both
expr1
and expr2
must be TIME
or DATETIME
expressions of the same type. This
code returns the value 01:37:38
:
SELECT TIMEDIFF('2000-01-01 01:02:03', '1999-12-31 23:24:25');