Skip to main content
1 of 2

It is in the case if you just use just first in the predicate.

It will do scan if you use first columns of composite key and non-key column of composite key.

To trick it you can just dummy predicates like this and then non-key column:

[A,B] is your index, [C] - another column

To utilize index you write as:

SELECT A,B,C,D,E FROM test WHERE A=1 AND B=B AND C=3