Oracle 19c SQL

  1. Home
  2. Docs
  3. Oracle 19c SQL
  4. Datetime Functions
  5. SYSDATE

SYSDATE

  • SYSDATE returns the current date and time of the operating system on which the database resides, taking into account the time zone of the database¬†server’s operating system that was in effect when the database was started.
Syntax: SYSDATE
  • This function requires no arguments.
  • The data type of the returned value is DATE.
  • The format returned depends on the value of the NLS_DATE_FORMAT initialization parameter.
SELECT SYSDATE curr_time FROM DUAL;

CURR_TIME
---------
12-NOV-20
  • By default SYSDATE does not display the time. You must use TO_CHAR conversion function to display the time along with date as per specified format.
SELECT TO_CHAR(SYSDATE, 'MM-DD-YYYY HH24:MI:SS') curr_time
  FROM DUAL;

CURR_TIME
-------------------
11-12-2020 15:45:10
Was this article helpful to you? Yes No

How can we help?