On Tue, Dec 12, 2000 at 12:20:00AM -0400, The Hermit Hacker wrote:
>
> one thing I've found to get around this is for any query that doesn't
> appear to use the index properly, just do:
>
> SET ENABLE_SEQSCAN=OFF;
> <query>
> SET ENABLE_SEQSCAN=ON;
>
> that way for those queries that do work right, ou haven't forced it a
> different route ..
I've heard there are other ways to give clues to the
optimizer, but haven't seen anything in the docs on it. Anyway, I have gotten
virtually all of the queries optimized as much as possible. Some of the
queries are written in such a way that they key off of things in 2 or more
tables, so that's kinda hard to optimize in any circumstance.
Any plans to optimize:
-Views
-IN (1,2,3)
-SELECT count(*) FROM x WHERE indexed_field='z'
Tim
--
Founder - PHPBuilder.com / Geocrawler.com
Lead Developer - SourceForge
VA Linux Systems