SELECT TIMEDIFF('1997-12-31 23:59:59.000001', '1997-12-30 01:01:01.000002'); : TIMEDIFF « Date Time Functions « MySQL Tutorial






mysql>
mysql> SELECT TIMEDIFF('1997-12-31 23:59:59.000001', '1997-12-30 01:01:01.000002');
+----------------------------------------------------------------------+
| TIMEDIFF('1997-12-31 23:59:59.000001', '1997-12-30 01:01:01.000002') |
+----------------------------------------------------------------------+
| 46:58:57.999999                                                      |
+----------------------------------------------------------------------+
1 row in set (0.02 sec)

mysql>








14.44.TIMEDIFF
14.44.1.TIMEDIFF(expr1,expr2) returns expr1 ¡§C expr2 expressed as a time value.
14.44.2.SELECT TIMEDIFF('1997-12-31 23:59:59.000001', '1997-12-30 01:01:01.000002');