# Composite Index (Continue...)

+ Reduced overhead: Building one composite index `(col1,col2,col3)`  is equivalent to building three indexes: `(col1)` ,  `(col1,col2)` , `(col1,col2,col3)`  
+ scenario where indexing can be used effectively
+ scenario indexes are used in parts (II)
+ scenario indexes cannot be used (III)
```
(I)
select * from t2 where c1 between 1 and 20;
select * from t2 where c1 = 3 and c2 > 5 and c2 < 10;
select * from t2 where c1 = 1 and c2 = 10 and c3 between 1 and 200;

(II)
select * from t2 where c1 between 1 and 20 and c2 = 100; -- (col1)
select * from t2 where c1 = 3 and c2 > 5 and c2 < 10 and c3 = 100; -- (col1, col2)

(III)
select * from t2 where c2 = 20 and c3 = 100;
select * from t2 where c3 = 100;
```
------------------------------------------------------------
[no notes]