Collections:
Convert Dates to Character Strings in Oracle
How To Convert Dates to Characters in Oracle?
✍: FYIcenter.com
You can convert dates to characters using the TO_CHAR() function as shown in the following examples:
SELECT TO_CHAR(SYSDATE, 'DD-MON-YYYY') FROM DUAL; -- SYSDATE returns the current date 07-MAY-2006 SELECT TO_CHAR(SYSDATE, 'YYYY/MM/DD') FROM DUAL; 2006/05/07 SELECT TO_CHAR(SYSDATE, 'MONTH DD, YYYY') FROM DUAL; MAY 07, 2006 SELECT TO_CHAR(SYSDATE, 'fmMONTH DD, YYYY') FROM DUAL; May 7, 2006 SELECT TO_CHAR(SYSDATE, 'fmDAY, MONTH DD, YYYY') FROM DUAL; SUNDAY, MAY 7, 2006
⇒ Convert Character Strings to Dates in Oracle
⇐ Convert Character Strings to Numbers in Oracle
2020-03-25, 4413🔥, 0💬
Popular Posts:
How Many Groups of Data Types in MySQL? MySQL support 3 groups of data types as listed below: String...
How To Start MySQL Server in MySQL? If you want to start the MySQL server, you can run the "mysqld" ...
Where to find reference information and tutorials on MySQL database functions? I want to know how to...
How To Escape Special Characters in SQL statements in MySQL? There are a number of special character...
How To Recover a Dropped Index in Oracle? If you have the recycle bin feature turned on, dropped ind...