Answer the question
In order to leave comments, you need to log in
Why is the request not working?
I can not understand why the request does not work and how to fix it.
$query = $pdo->prepare("
SELECT *, WEIGHT() AS weight
FROM {$index} WHERE MATCH (:search)
OPTION ranker=proximity_bm25, max_query_time=3, max_matches=300
");
$query->bindValue(':search', $q, \PDO::PARAM_STR);
$query->execute();
$rows = $query->fetchAll(\PDO::FETCH_ASSOC);
Answer the question
In order to leave comments, you need to log in
SELECT *, WEIGHT() AS weight FROM companyIndex WHERE MATCH (Company | *Company*) OPTION ranker=proximity_bm25, max_query_time=3, max_matches=300
Компания | *Компания*
https://dev.mysql.com/doc/refman/8.0/en/fulltext-s...
MATCH (col1,col2,...) AGAINST (expr [search_modifier])
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question