Home » SQL & PL/SQL » SQL & PL/SQL » date datatype
date datatype [message #581] Fri, 22 February 2002 07:57 Go to next message
Kristin
Messages: 1
Registered: February 2002
Junior Member
How do I populate a table with time? The data type I used is date and it works fine with my date fields when I use the format DD-MMM-YY. What format do I use when I only want to enter the time or date and time together. The format '20-Jan-02 10:00:00 AM' doesn't work.

Kristin
Re: date datatype [message #585 is a reply to message #581] Fri, 22 February 2002 09:59 Go to previous message
Suresh Vemulapalli
Messages: 624
Registered: August 2000
Senior Member
oracle always stores date with time. oracle adds 00:00:00 to date when u dont provide time part.

insert into datetable
values ( to_date('01/01/2001 10:00:00','mm/dd/yyyy hh24:mi:ss');
Previous Topic: Re: Week to date
Next Topic: View details
Goto Forum:
  


Current Time: Tue Apr 16 15:24:41 CDT 2024