DatePart


 

DatePart>date,interval,result

 

Returns part of a date specified by interval. Interval can be one of:

 

D: Day of month

M: Month

Y: Year

 

The date should be in a format recognised by the system.  Use DateLocal to generate a date in local system format.

 

See also: DateAdd, DateDiff, DateLocal

 

Example

 

GetDate>today

DatePart>today,M,thisMonth