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: SELECT BETWEEN Dates

Re: SELECT BETWEEN Dates

From: Kingsley Sawyers <no_at_way.im.telling>
Date: Wed, 11 Aug 1999 15:47:39 +0100
Message-ID: <7os2c4$drc$1@lure.pipex.net>


Try ....WHERE TRUNC(REV_DATE) BETWEEN... - the time element in the dates is confusing the results.

Eamonn Keating wrote in message <7os1ab$qng$1_at_scotty.tinet.ie>...
>On the oracle database the following statement will not retrieve any rows
>SELECT PartCode,SPEC_REV_NO, to_char(CHANGE_DATE_TIME,'dd/Mon/yyyy
>hh24:mi:ss'), to_char(REV_DATE,'dd/Mon/yyyy'),Userid,Comments FROM SPECAUD
>WHERE REV_DATE BETWEEN to_date( '11-Aug-1999' , 'dd-mon-yyyy') AND
>o_date( '11-Aug-1999' , 'dd-mon-yyyy')
>
>wheras the following will
>
>SELECT PartCode,SPEC_REV_NO, to_char(CHANGE_DATE_TIME,'dd/Mon/yyyy
>hh24:mi:ss'), to_char(REV_DATE,'dd/Mon/yyyy'),Userid,Comments FROM SPECAUD
>WHERE REV_DATE BETWEEN to_date( '11-Aug-1999' , 'dd-mon-yyyy') AND
>o_date( '12-Aug-1999' , 'dd-mon-yyyy')
>
>for data on 11-Aug-1999 ?
>any help would be appreciated
>
>Regards
>Eamonn
>
>
Received on Wed Aug 11 1999 - 09:47:39 CDT

Original text of this message

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