MySQL DAYNAME()
MySQL 날짜함수, 시간함수
DAYNAME()
- weekday의 이름을 return.
DAYNAME(date)
의 형태
Returns the name of the weekday for date. The language used for the name is controlled by the value of the lc_time_names system variable.
mysql> SELECT DAYNAME('2020-03-01') ;
+-----------------------+
| DAYNAME('2020-03-01') |
+-----------------------+
| Sunday |
+-----------------------+
1 row in set (0.00 sec)
mysql> SELECT DAYNAME(NOW()) ;
+----------------+
| DAYNAME(NOW()) |
+----------------+
| Wednesday |
+----------------+
1 row in set (0.00 sec)
mysql> SELECT DAYNAME('2020-03-00') ;
+-----------------------+
| DAYNAME('2020-03-00') |
+-----------------------+
| NULL |
+-----------------------+
1 row in set, 1 warning (0.00 sec)