vBulletin Search Engine Optimization
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Hi! My SQL query: SELECT * FROM articles WHERE MATCH(title, description) AGAINST ("word1 word2"); Search index is correct and every search with one word works well. But I am confused because this seems to find items that contain one of the words, but not both. How can I fix this? Regards, Markus |
| ||||
| On Jul 31, 1:14 pm, Markus <m...@markus-franz.de> wrote: > Hi! > > My SQL query: > SELECT * FROM articles WHERE MATCH(title, description) AGAINST ("word1 > word2"); > > Search index is correct and every search with one word works well. But > I am confused because this seems to find items that contain one of the > words, but not both. How can I fix this? > > Regards, > Markus You will need to use boolean mode. http://dev.mysql.com/doc/refman/5.0/...t-boolean.html Your query will change to select * from articles where match(title, description) against ('+word1 +word2' in boolean mode); -cheers, Manish |