Re: Choosing Indices
Posted in 1996
In article <4em3mj$t1l@cssun.mathcs.emory.edu>
jkormann@Trenton.EDU "Joseph Kormann" writes:
>
> Select *
> from table1
> where x = '1' and
> y = '11';>
Try creating an index on table1( x, y ) and this above example should
be very fast.
However, which column you put first in the index matters. Chose the one
with the most number of discrete values as then fewer entries will also
have 'y=11'.
Hope this helps.
--
============================================================================
Sally Woolrich | This mail contains my personal
sally@excelsis.demon.co.uk | views not those of my employer!
============================================================================