| List: | General Discussion | « Previous MessageNext Message » | |
| From: | Frederik Lindberg | Date: | January 1 1970 12:00am |
| Subject: | LIKE '%foo%' (was: mysql is a ...) | ||
| View as plain text | |||
On Sun, 14 Nov 1999, Michael Widenius wrote: > Frederik> internals. Maybe it is very easy to speed up the index scan, or maybe > Frederik> MySQL incorrectly decides that the index is worthless (even though a > Frederik> complete index scan is cheaper than a complete data scan). > > The above isn't really true; If the records are short, it's faster to > scan the table than scan the index (as scanning the index involves > much more seeks) Yes. I'm usually assuming that the index fits and is cached in memory, but the table itself is too big. Back to the original problem: Is there a way to optimized LIKE '%foo%'? -Sincerely, Fred Fred Lindberg, Inf. Dis., WashU, St. Louis, MO, USA
