I have a query that is supposed to search from the db and return the most closely matching results.
Problem is it is just returning results having a single word. I'm using full-text search in binary mode.
The query is as below:
select * from category
where CategoryActive='Y'
AND labelCategory != '1'
and labelCat开发者_StackOverflowegory != ''
and labelCategory != '2'
and (labelCategory like '%inkjet%'
or labelCategory like '%laser%')
and Match (CategoryID, CategoryName,CategoryFeedName,
CategoryDescription, CategorySEOTitle,
CategorySEPDescription, CategorySEPKeywords)
Against('$value' IN BOOLEAN MODE)
order by `CategoryName` asc;
Please make a suggestion or indicate the mistakes in the query above.
精彩评论