User ORDER BY First Name

Chris Wilkinson wrote:

can anybody explain this to me please!  I search am searching through a database
with first name and last names.  BTW I use mysql 4.0.13 on RedHat Linux 9.0 in
case that matters.  I created a fulltext search on both fields together so I can
search them like this:

mysql> SELECT first_name,last_name FROM names_table WHERE
MATCH(first_name,last_name) AGAINST ('+wilkinson* chris*' IN BOOLEAN MODE);

The problem is that for some reason the record with first_name=fran is displayed
first even though the score is lower than the record where first_name=christopher

mysql> SELECT first_name,last_name,MATCH(first_name,last_name) AGAINST
('+wilkinson* chris*' IN BOOLEAN MODE) AS score FROM names_table WHERE
MATCH(first_name,last_name) AGAINST ('+wilkinson* chris*' IN BOOLEAN MODE);
+-------------+-----------+-----------------+
| first_name  | last_name | score           |
+-------------+-----------+-----------------+
| Fran        | Wilkinson |               1 |
| Christopher | Wilkinson | 1.3333333730698 |
+-------------+-----------+-----------------+
2 rows in set (0.01 sec)

Can somebody please explain why this is and how I can get Christopher to show up
before Fran!  Thanks!




--


Kevin J Citron
Sr. Object Imagineer
Optimized Objects, Inc.
EL Paso, Texas 79930
(915) 565-5777/566-2403




-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]



Reply via email to