Returns the current system date and time.
getdate()
select getdate()
Nov 25 1995 10:32AM
select datepart(month, getdate())
1
These examples assume a current date of November 25, 1995, 10:32 a.m.:
select datename(month, getdate())
November
getdate, a date function, returns the current system date and time.
For more information about date functions, see “Date functions”.
SQL92 – Compliance level: Transact-SQL extension.
Any user can execute getdate.
Datatypes Date and time datatypes.