portableSql

Week Portable SQL Function

Syntax

Week as N (DateTime as D)

Week as N (DateTime as T)

Arguments

DateTimeDate Time

A field or value.

Returns

resultNumeric

Returns the week number of the year from a date or datetime value.

Description

Extract the week number of the year from a date or datetime value.

Discussion

The Week function extracts the week number of the year from a date or datetime value.

Week() function executed on the Northwind Access database
SELECT FIRST 1 CurrentDateTime() AS Now, Week(CurrentDateTime()) AS Expr1 FROM Orders
=10/10/2019 12:48:35 00 pm|41