Re: OnLine Optimizer with compound indices??
Posted in 1995
Just a quick follow-up. This thread has been moving on with the
assumption that "||" means "OR". Actually, it is Informix's concatenation
operator. The best answer I've found to my original problem is to
use a statement such as:
SELECT A,B FROM table WHERE A >= "XXX" and A || B > "XXXX"
With this type of statement, Informix uses the index (A,B), applying a
filter of A || B > "XXXX", but it also applies a lower-level filter of
A >= "XXX", which appears to have the effect of making Informix jump
directly to the desired "A" value in the index, then scanning the
rest of the indices to satisfy the second (concatenated) condition.
Not completely what I was looking for, but decidedly better than
scanning *all* the indices and applying a filter.
Thanks for all the assistance that was offered to this question.
--
-------------------------------------------------------------------------------
Todd Saylor | Bi-Tech Software, Inc.
"No matter where you go, there you are" | (916) 891-5281
----------- Opinions expressed are subject to change without notice -----------