dayofweek()
Returns the integer number of days since the preceding Sunday, as a timespan
.
Syntax
dayofweek(
date)
Parameters
Name | Type | Required | Description |
---|---|---|---|
date | datetime | ✓ | The datetime for which to determine the day of week. |
Returns
The timespan
since midnight at the beginning of the preceding Sunday, rounded down to an integer number of days.
Examples
print dayofweek(datetime(1923-11-30 10:00:05)) // time(0.00:00:00), indicating day