MySQL fulltext search Boolean mode confusion

I'm getting a bit confused when trying to set up a search utilizing fulltext search in boolean mode. Here is the query I'm using:

$query = "SELECT *,

       MATCH(title) AGAINST('$q' IN BOOLEAN MODE) AS score

       FROM results

       WHERE MATCH(title) AGAINST('$q' IN BOOLEAN MODE)

       ORDER BY score DESC";

When I run a search for +divorce+refinance, the results returned are:

1) Divorce: Paying Off Spouse = Rate/Term Refinance
2) Divorce - What to Look Out For Regarding Divorced Borrowers

Am I right in thinking that the second result should not be appearing, as it does not have both words? If not, how can I create that functionality?

Answers


Maybe I am mistaken, but if you search this string +divorce+refinance you get a weird result. If you want to search both words, your should search for +divorce +refinance (with a space between).

I tested it and it returns only one row:

Divorce: Paying Off Spouse = Rate/Term Refinance

Need Your Help

Error accessing Birthday variable using Watir during gmail sign-up

ruby watir watir-webdriver firewatir

I am trying to create the gmail account through watir. As part of it while I am trying to select the birthday using div element I am unable to do.

background image is not showing

jquery html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">