Answer the question
In order to leave comments, you need to log in
Why does Query Builder formulate the query incorrectly?
I use the query builder Query Builder for SphinxQL . Gives the error "[1064] You have an error in your SQL syntax". And the query itself is obtained from the Query Builder
like this: "SELECT title FROM userads WHERE MATCH('(@title searchtext)') AND active = 1". Namely, it swears at the part "MATCH('(@title subject)') ".
I understand that it is correct to write MATCH (`title`) AGAINST ('$searchtext'). But why is the builder composing the request incorrectly?
Here is my request:
$query = (new SphinxQL($conn))->select('title')
->from('userads')
->match('title', 'searchtext')
->where('active', '=', 1);
$result = $query->execute();
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question