DAYOFWEEK(date)
返回日期星期几的索引 (1 = Sunday, 2 = Monday, ., 7 = Saturday);这些索引值对应于ODBC标准。
mysql> SELECT DAYOFWEEK('1998-02-03'); +---------------------------------------------------------+ |DAYOFWEEK('1998-02-03') | +---------------------------------------------------------+ | 3 | +---------------------------------------------------------+ 1 row in set (0.00 sec)