Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Relative times
carolek_at_ix.netcom.com (Carole Kaufman) wrote in
news:72330e0d.0111091807.55cc5700_at_posting.google.com:
> I would like to create a query in Oracle which checks data for the
> last 4 hours. In Oracle, I know that if I want a relative day, I'd
> say "Sysdate - 1". But how do I make it go to hours? When I try
> 'sysdate - 0.17', the query takes forever to run - but it runs well
> with whole numbers. We're on Oracle 7.3.
>
> Any and all help appreciated.
SYSDATE-(1/24) = 1 hour before now.
SYSDATE-(4/24) = 4 hours before now.
HTH & YMMV! Received on Sat Nov 10 2001 - 08:42:22 CST
![]() |
![]() |