文件名称:mysql 日期函数.txt
文件大小:11KB
文件格式:TXT
更新时间:2013-08-05 18:53:29
mysql 日期处理,mysql,函数,mysql函数
1. 2.DAYOFWEEK(date) 3.WEEKDAY(date) 4.DAYOFMONTH(date) 5.DAYOFYEAR(date) 6.MONTH(date) 7.DAYNAME(date) 8.MONTHNAME(date) 9.QUARTER(date) 10.WEEK(date) WEEK(date,first) 11.YEAR(date) 12.HOUR(time) 13.MINUTE(time) 14.SECOND(time) 15.PERIOD_ADD(P,N) 16.PERIOD_DIFF(P1,P2) 17.DATE_ADD(date,INTERVAL expr type) DATE_SUB(date,INTERVAL expr type) ADDDATE(date,INTERVAL expr type) SUBDATE(date,INTERVAL expr type) EXTRACT(type FROM date) 18.TO_DAYS(date) 19.FROM_DAYS(N) 20.DATE_FORMAT(date,format) 21.TIME_FORMAT(time,format) 22.CURDATE() 23.CURTIME() 24.SYSDATE() 25.UNIX_TIMESTAMP() UNIX_TIMESTAMP(date) 26.FROM_UNIXTIME(unix_timestamp) FROM_UNIXTIME(unix_timestamp,format) 27.SEC_TO_TIME(seconds) 28.TIME_TO_SEC(time)