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: Which Date comparison more efficient?

Re: Which Date comparison more efficient?

From: Jim Kennedy <kennedy-down_with_spammers_at_attbi.com>
Date: Wed, 07 May 2003 02:16:09 GMT
Message-ID: <J%Zta.760221$L1.215309@sccrnsc02>


Bench mark it. How about
adate>= to_date('10-10-03','MM-DD-YY')
and adate< to_date('10-11-03','MM-DD-YY') That would be a LOT more efficient than the other two assuming there is an index on adate.
Jim

-- 
Replace part of the email address: kennedy-down_with_spammers_at_attbi.com
with family.  Remove the negative part, keep the minus sign.  You can figure
it out.
"Skinny Guy" <skinnychineseguy_at_hotmail.com> wrote in message
news:f9b5a61d.0305061451.4cc8051b_at_posting.google.com...

> 1) trunc(aDate) = to_date('10-10-03','MM-DD-YY')
>
> or
>
> 2) to_char(aDate,'MM-DD-YY') = to_date('10-10-03','MM-DD-YY')
Received on Tue May 06 2003 - 21:16:09 CDT

Original text of this message

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