Oracle Version: 10.2.0.4
Why is to_timestamp function truncating sysdate (to 12:00 AM) ?
SQL > select value from nls_session_parameters where parameter='NLS_DATE_FORMAT';
VALUE
----------------------------------------
DD-MON-RR
SQL > select to_timestamp(Sysdate) From dual;
TO_TIMESTAMP(SYSDATE)
---------------------------------------------------------------------------
28-JUL-10 12.00.00 AM
Documentation
http://youngcow.net/doc/oracle10g/server.102/b14200/functions193.htm#sthref2021
is only talking about CHAR, VARCHAR2, NCHAR, or NVARCHAR2 as input datatypes. Is this the reason?
I just wanted to see Time quickly in SQL*Plus without having to set NLS_DATE_FORMAT every time.