TO DATE
From Oracle FAQ
⧼orafaq-jumptonavigation⧽⧼orafaq-jumptosearch⧽
TO_DATE is a SQL function for converting a character string to an Oracle DATE.
Syntax
The syntax for the TO_DATE function is:
to_date( string, [ format_mask ], [ nls_language ] )
Where:
- string is the string that will be converted to a date.
- format_mask is optional. This is the format that will be used to convert the string to a date.
- nls_language is also optional. This is the NLS language (regional settings) used to convert the string to a date.
Examples
SQL> SELECT TO_DATE('4-JAN-2009', 'DD-MON-YYYY') FROM dual; TO_DATE(' --------- 04-JAN-09