How many indexes will actually get used?
Posted
by Ender
on Stack Overflow
See other posts from Stack Overflow
or by Ender
Published on 2010-05-27T05:51:53Z
Indexed on
2010/05/27
6:01 UTC
Read the original article
Hit count: 217
I'm writing a page that does very simple search queries, resulting in something like:
SELECT * FROM my_table WHERE A in (a1, a2, a3) AND B in (b1, b2) AND C in (c1, c2, c3, c4) AND
And so on for a variable number of columns, usually ~5. If I create a separate index for each column (one for A, one for B, one for C, not (A,B,C)), will all of them be used in the above query?
© Stack Overflow or respective owner