Hi Simone,
I'm sorry for the slow response.
It sounds like you may have already found the `:sql` option for search calls to pass through a limited set of SQL-based options as part of populating the search results:
https://freelancing-gods.com/thinking-sphinx/v5/searching.html#advanced
Granted, that's quite old, and the syntax was inspired by ActiveRecord's pre v3 approach. 😓 But there isn't anything else of this manner in Thinking Sphinx.
I realise it may not be ideal, but I would recommend instead querying Sphinx for the instance ids (using Article.search_for_ids instead of Article.search), and then - as/when needed - perform the SQL query using those ids. This avoids the initial SQL query to populate the search results as ActiveRecord objects. Would this be feasible in your situation?
Kind regards,
--
Pat