How to make a query through the query MATCH (column1, column2) AGAINST ('keyword' IN BOOLEAN MODE) in an InnoDB table with two fields indexed by FULLTEXT, including the operators that are in the word being searched?
Understand:
SELECT * FROM languages WHERE MATCH (title, body) AGAINST ('C++' IN BOOLEAN MODE);
Remembering that the +
sign is one of the operators that can be used in the word to be searched IN BOOLEAN MODE, such as -
, <
, >
, @
, among others to obtain results more extended.
So, the query in our example above fails due to the word C ++ , which is actually interpreted as being a letter followed by two operators (C ++
). >
I would like the search to ignore the operators but to search with them IN BOOLEAN MODE, it can not be IN NATURAL LANGUAGE, unless the natural language mode can even bring the 50% that are discarded from the search, or either, bring the result with all existing values as in Boolean mode, without ignoring words that are very repetitive.
In order to complete the information and maybe to elucidate other new ways of solving the problem, the programming language that will implement the search process will be PHP and the word to be searched will be loaded into a variable via POST (AJAX) after the user search field. Any other path that leads to the same result is also welcome!