From: "Mark Wagoner" <mwagoner@iac.net>
Newsgroups: comp.databases.oracle.misc
Subject: Re: How to add seconds to a date field?
Date: Fri, 2 Feb 2001 15:34:58 -0500
Organization: Internet Access Cincinnati
Lines: 19
Message-ID: <95f5lj$ppl$1@genma.iac.net>
References: <95f4er$iru$1@nnrp1.deja.com>
Reply-To: "Mark Wagoner" <mwagoner@iac.net>
NNTP-Posting-Host: zoom-11.adsl.iac.net
X-Trace: genma.iac.net 981146099 26421 199.6.50.11 (2 Feb 2001 20:34:59 GMT)
X-Complaints-To: abuse@iac.net
NNTP-Posting-Date: 2 Feb 2001 20:34:59 GMT
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.00.2919.6600
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6600


An Oracle date is only down to the whole second, so you cannot store
milliseconds in the date field.  You would have to convert the date to some
form of Julian value and store it as a number.

To add 20 seconds to an existing date, you just do the math.  1 second is  1
/ (24 * 60 * 60) = .0000115  To add 20 seconds, you add .0000115 * 20.

<anooshak@my-deja.com> wrote in message news:95f4er$iru$1@nnrp1.deja.com...
> Inside my stored procedure I like to get a column of type date and add
> 20 seconds to it. Any suggestions?
> Also could I get miliseconds in a date data type?
>
> Anoosh
>
>
> Sent via Deja.com
> http://www.deja.com/



