Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.tools -> Re: date column in where clause -> suppressing index?
Yes that is possible to some extent, but we are using RW dbtools (C++) and I am not sure wheter they support that.
Thanks for the reply!
/Jerra
Brian Peasland wrote:
> Jerra,
>
> Why don't you use the BETWEEN operator? For example, to search a table
> for today's date:
>
> SELECT * FROM table WHERE date_column BETWEEN TO_DATE('07/26/2000
> 00:00','MM/DD/YYYY HH24:MI')
> AND TO_DATE('07/26/2000
> 23:59','MM/DD/YYYY HH24:MI');
>
> HTH,
> Brian
>
> Jerra wrote:
> >
> > When using date and time how do I search for specific dates most efficently?
> > Using where trunc(date,'DD') = to_date('26-07-2000','MM-DD-YYYY') the index
> > for the date column can't be used.
> > The time portion is important and can't be 00:00:00 and there is a lot of
> > searches for posts for a specific day.
> >
> > TIA!
> >
> > /Jerra
>
> --
> ========================================
> Brian Peasland
> Raytheons Systems at
> USGS EROS Data Center
> These opinions are my own and do not
> necessarily reflect the opinions of my
> company!
> ========================================
Received on Wed Jul 26 2000 - 00:00:00 CDT
![]() |
![]() |