扫码一下
查看教程更方便
to_days()函数 返回转换为天的日期参数。
to_days()函数语法如下
to_days(date)
给定一个日期,返回一个天数(自 0 年以来的天数)。
mysql> select to_days(950501);
---------------------------------------------------------
| to_days(950501) |
---------------------------------------------------------
| 728779 |
---------------------------------------------------------
1 row in set (0.00 sec)