mysql 取两个日期之间距离的小时

mysql> select hour(TIMEDIFF('2010-02-08 10:50:10','2010-02-06 9:00:00'));


+------------------------------------------------------------+
| hour(TIMEDIFF('2010-02-08 10:50:10','2010-02-06 9:00:00')) |
+------------------------------------------------------------+
|                                                         49 |
+------------------------------------------------------------+

你可能感兴趣的:(mysql 取两个日期之间距离的小时)