Skip to content
Related Articles

Related Articles

Improve Article

Date() and DateAdd() Function in MS Access

  • Last Updated : 03 Sep, 2020

1. Date() Function :
Date() function returns the current date of the system. In this function, no parameter will be passed and it will return the current date.

Syntax :

Date() 

Example :

SELECT Date() AS CurrentDate;

Output –

CurrentDate
9/2/2020

2. DateAdd() Function :
DateAdd() function will add the time interval and date to the given date and return it. In this function, the first parameter will be the interval notation and second parameter will be the number that will be added and the third parameter will be the date,



IntervalDescription
yyyyYear
qQuarter
mmonth
yDay of the year
dDay
wWeekday
wwWeek
hhour
nMinute
sSecond

Syntax :

DateAdd(interval, number, date) 

Example-1 :

SELECT DateAdd("yyyy", 3, #02/09/2020#);

Output –

Output :
2/9/2023

Example-2 :

SELECT DateAdd("m", 3, Date()) As Date;

Output –

Output :
12/2/2020
My Personal Notes arrow_drop_up
Recommended Articles
Page :