MATCH ... AS relevancy FROM

From: Date: Thu, 01 Jul 2004 04:10:35 +0000
Subject: MATCH ... AS relevancy FROM
Groups: php.general 
Request: Send a blank email to php-general+get-189422@lists.php.net to get a copy of this message
David> http://dev.mysql.com/doc/mysql/en/Fulltext_Boolean.html David> Quote: David> They do not automatically sort rows in order of decreasing relevance. David> You can see this from the preceding query result: The row with the highest relevance is David> the one that contains ``MySQL'' twice, but it is listed last, not first. Has anyone seen something like this work? SELECT *, MATCH (ST,BT,AT) AGAINST ('margaret atwood' IN BOOLEAN MODE) AS relevancy FROM ccl_main WHERE MATCH (ST,BT,AT) AGAINST ('margaret atwood' IN BOOLEAN MODE) ORDER BY relevancy DESC; Thanks David. John

« previous php.general (#189422) next »