Answer the question
In order to leave comments, you need to log in
Can sphinx add an attribute from a query?
Users have many posts, posts have many likes. You need to count the number of likes for all user posts. Currently, this is done using sphinx via sql_attr_uint, and the amount itself is calculated via a nested query (mysql). I would like to at least get away from nested queries, for example, use sql_attr_multi and select the number of likes in it, but you cannot sort by this field. Is there a way to put an attribute in a select so that you can eventually sort by it?
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