Quantcast
Viewing all articles
Browse latest Browse all 23857

Multiple indexes on a table with various combinations

Hi Experts,

This post is similar to my previous one on indexing. am just trying to understand proper indexing strategy.

Assuming that i have to use following queries frequently.

  1. select Col1, Col2, Col3 from tab where col4='some value'
  2. select Col1, Col2, Col3 from tab where col5='some value'
  3. select Col1, Col2, Col3 from tab where col6='some value'
  4. select Col1, Col2, Col3 from tab where col7='some value'
  5. select Col1, Col2, Col3 from tab where col8='some value'
  6. select Col1, Col2, Col3 from tab where col9='some value'
  7. select Col1, Col2, Col3 from tab where col10='some value'

here, my doubt is, do we need to create "1 clustered + 6 NC covering" indexes (total 7) as we have 7 different columns in the where clause in 7 different select statements? Or, is there any better way of doing this?

Thanks,

Shiva


Viewing all articles
Browse latest Browse all 23857

Trending Articles