Hi Kim, On Thu, 2002-03-21 at 09:15, Kim Kohen wrote: > G'day Arjen
Indeed, hi fellow Aussie ;-) > > FULLTEXT search generally uses an index (the FULLTEXT index), so the > > server will not use an index on Writer. > So is an index on Writers worthless in this circumstance? My concern would > be if someone did a query using the writer's name as the _only_ criteria. > Would this not be inefficient if it's not indexed for a search on several > hundred thousand rows? Of course. I was just saying that in the SELECT example you have, the server will generally always pick the fulltext index, and not use the Writer index. Naturally, the situation can be different in a different SELECT, for instance one that does not have a fulltext search but only the LIKE Writer = "some%"... clause in the WHERE. There, of course, the server will indeed use an index on Writer column if possible. > > There are situations where the optimiser will not use a fulltext index: > > 2) if the MATCH is part of an expression. > > Therefore, > > effectively, two indexes can/will be used! ;-) > My newbie mind spins a little faster:) I think I understand what you're > saying but I think I need further explanation of "the MATCH is part of an > expression". Could you perhaps offer an example? Does all of this only > apply to mysql 4.x where the 'in boolean mode' is available? Not quite. It is a bit long to explain here though, but have a look at the examples in the manual. You will find that there are different ways of specifying a fulltext query, one of which will actually get you a "relevance" value which you can for instance use to order the result set, or limit it. Regards, Arjen. -- Get MySQL Training Worldwide, http://www.mysql.com/training/ __ ___ ___ ____ __ / |/ /_ __/ __/ __ \/ / Mr. Arjen G. Lentz <[EMAIL PROTECTED]> / /|_/ / // /\ \/ /_/ / /__ MySQL AB, Technical Writer, Trainer /_/ /_/\_, /___/\___\_\___/ Brisbane, QLD Australia <___/ www.mysql.com --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php