Week numbers in Oracle

How to get the week number from a date

To get the ISO week number (1-53) from a date in the column datecol, use SELECT TO_CHAR(datecol, 'IW') FROM ….

To get the corresponding four-digit year, use SELECT TO_CHAR(datecol, 'IYYY') FROM ….

Read more about TO_CHAR() in the Oracle manual.

Read more

Learn more about week numbers and the ISO week numbering scheme in this little primer.