Home » SQL & PL/SQL » SQL & PL/SQL » Time is not saved with date. (Oracle 8i)
Time is not saved with date. [message #361935] Fri, 28 November 2008 11:09 Go to next message
mamalik
Messages: 266
Registered: November 2008
Location: Pakistan
Senior Member

Dear

I have a column with Date datatype in a table. I am storing date with time to calulate number of hours later. It is working fine but when i save datetime like '29-NOV-2008 12:00:00 AM' then only '29-NOV-2008' is saved in table. I know that i can get it by TO_CHAR(COLUMN_NAME,'DD-MM-YYYY HH:MI:SS AM'). But i want it should be saved in table as '29-NOV-2008 12:00:00 AM' instead of '29-NOV-2008'.

How can i do it.

Regards.
Muhammad Asif.

Re: Time is not saved with date. [message #361938 is a reply to message #361935] Fri, 28 November 2008 11:29 Go to previous messageGo to next message
Michel Cadot
Messages: 64139
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Date is not save with any format.
You have date AND time and the proof is that you can see it with TO_CHAR.

Regards
Michel
Re: Time is not saved with date. [message #361943 is a reply to message #361938] Fri, 28 November 2008 11:34 Go to previous message
mamalik
Messages: 266
Registered: November 2008
Location: Pakistan
Senior Member

Thanks a lot Dear Michel Uncle. Smile
Previous Topic: Problem on Fine Grained Auditing
Next Topic: How to use the CASE STATEMENT in PL/SQL
Goto Forum:
  


Current Time: Thu Dec 08 19:51:57 CST 2016

Total time taken to generate the page: 0.05744 seconds