Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Query Performance: Using DECODE() instead of IN()
use sql_trace/tkprof, autotrace, execution plans with real volumes of
data to see how these perform.
actually runstats is a great way also to compare two things like this also.
http://asktom.oracle.com/~tkyte/runstats.html
autotrace shows the opposite of what you propose below
>
> I think I recall somewhere that using a decode uses an index scan where
> using IN() uses a full table scan, however I can't seem to prove this.
>
> Trying to search for in and decode in google is not fun. Any ideas?
>
> PT
Received on Mon Oct 20 2003 - 16:09:39 CDT