Description: Returns the specified
interval part of the date given.
Interval : yyyy for year, q for quarter, m for
month, d for day, ww for week, w for weekday, y for day of year, h for
hour, n for minute, s for second. Date1 : The date and time to
consider FirstDayofWeek : Optional. This constant specifies which day
is considered to be the start of the week. 0 is the system default, 1 is
Sunday, 2 is Monday, 3 is Tuesday, and so on. FirstWeekOfYear :
Optional. This constant specifies the first week of the year. If not
specified the first week of the year is considered the week of January the
1st. 0 is the system default, 1 is week of January the 1st, 2 starts
with the week that has at least 4 days, 3 starts the year with the first
full week.
Example:
Determine the year part
of the cuthrrent
date. =datepart("yyyy",NOW())
Determine the quarter of the
current date. =datepart("q",NOW())
Determine the month of the
current date. =datepart("m",NOW())
Determine the day of year of the
current date. =datepart("y",NOW())
Determine the day part of the
current date. =datepart("d",NOW())
Determine the week day part of the
current date. =datepart("w",NOW())
Determine the week part of
the current date. =datepart("ww",NOW())
Determine the hour part of
the current date and
time. =datepart("h",NOW())
Determine the minute part of
the current date and
time. =datepart("n",NOW())
Determine the seconds part of
the current date and
time. =datepart("s",NOW())