Description
The WEEKFORYEAR( ) function returns the calendar week of a date, in the range 1 to 53.
This function has the form:
SELECT WEEKFORYEAR(date)
Parameter | Description |
---|---|
date | A date |
Return Value
Calender week of a date, in the range 1 to 53.
Examples
The following example shows the basic use of this function:
mysql> SELECT WEEKOFYEAR('2008-02-20');
->8