Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Update

Re: Update

From: Andreas Stephan <andreas.stephan.as_at_bayer-ag.de>
Date: Tue, 4 Sep 2001 13:52:24 +0200
Message-ID: <9n2f9o$2gi1@byz672.bayer-ag.com>


update tablename set date_time_field = to_date('13-JAN-2001','DD-MON-YYYY')   where condition;

will do it since there is no difference in Oracle between date and date_time fields.
A date field ever contains the time part though in the example above it will be truncated (set to 0am)

HTH
Andy

jop <jop_at_novabase.pt> schrieb in im Newsbeitrag: 5U2l7.57733$Fb.80595051_at_newsserver.ip.pt...
> I need help on SQL.
> I have a Date field that stores date and time. Now I want to have only
date.
> How to write an update SQL to update all rows with date only?
>
>
Received on Tue Sep 04 2001 - 06:52:24 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US