扫码一下
查看教程更方便
curtime()函数 添加日期。
curtime()函数语法如下
curtime()
返回当前时间作为 'hh:mm:ss' 或 hhmmss 格式的值,具体取决于函数是在字符串中还是在数字上下文中使用。该值以当前时区表示。
mysql> select curtime();
---------------------------------------------------------
| curtime() |
---------------------------------------------------------
| 23:50:26 |
---------------------------------------------------------
1 row in set (0.00 sec)
mysql> select curtime() 0;
---------------------------------------------------------
| curtime() 0 |
---------------------------------------------------------
| 235026 |
---------------------------------------------------------
1 row in set (0.00 sec)