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

Home -> Community -> Usenet -> c.d.o.server -> Re: Date Comparison

Re: Date Comparison

From: Zev Sero <zsero_at_mail.idt.net>
Date: 1996/12/13
Message-ID: <32b12d09.55926667@news.idt.net>#1/1

Steve Dirschel <steve_dirschel_at_cargill.com> wrote:

>Why do I not get 2 rows returned when I try the select * from dummy
>where a = '10-DEC-96' ? I realize I can do a "less than 11-DEC-96 and
>greater than 10-DEC-96" but it seems like I shouldn't have to do all
>of that typing.

You don't get any rows that are exactly equal to '10-DEC-96' because the value you're comparing to is assumed to be midnight, and the values in the table are the time that the inserts took place. What you want is

    select * from dummy where trunc(a) = '10-DEC-96'; This will give you all values for that day.

--
Zev Sero		Don't blame me, I voted for Harry Browne
zsero_at_mail.idt.net
zsero_at_technimetrics.com
Received on Fri Dec 13 1996 - 00:00:00 CST

Original text of this message

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