column weighting in FULLTEXT searches (MySQL)
Posted: Mon Jul 31, 2006 8:01 am
Hello all, this is my first post!
a quick question: does anyone know how I can make one column's contents more 'important' than another's when using FULLTEXT searches?
of the two columns searched event_title and event_description, i want event_title to be twice as important, maybe more..
Thanks in advance for any answers.
-Robin!
a quick question: does anyone know how I can make one column's contents more 'important' than another's when using FULLTEXT searches?
Code: Select all
$search="naked ladies";
$search_rs=mysql_query("select *,
match (`event_title`,`event_description`) against ('$search') AS score
from `li_events` e LEFT JOIN `li_cats` c on e.cat_id=c.idc
WHERE MATCH (`event_title`,`event_description`) against ('$search')
ORDER BY score DESC");of the two columns searched event_title and event_description, i want event_title to be twice as important, maybe more..
Thanks in advance for any answers.
-Robin!
Code: Select all