Hi Misha Sphinx always paginates - there’s no way to turn that off. You can request really large pages though (the default maximum is 1000 records, but that can be modified): http://pat.github.io/thinking-sphinx/advanced_config.html#large-result-sets
I’m not sure I quite understand what you’re after, though… if you want the item_variations loaded from the database alongside each item (eager loading), then you can pass through either :joins or :include options nested within the :sql option. Same goes for :select. http://pat.github.io/thinking-sphinx/searching.html#advanced It’s worth noting, though, that Sphinx itself has no concept of joins - there’s no way to tie one index to another. Does that help? Have I missed something? — Pat On 6 Nov 2014, at 3:05 am, Misha Slyusarev <[email protected]> wrote: > Hello Pat > > Any ideas how I can do that? Get an array of all items? > > Thanks. > > On Tuesday, 4 November 2014 21:16:52 UTC+2, Misha Slyusarev wrote: > Or maybe there is a way I can obtain all the found items in array? Skip > pagination stuff and get all the found items to manipulate them in memory? > > On Monday, 3 November 2014 18:37:00 UTC+2, Misha Slyusarev wrote: > I would like to be able ordering by a calculated field. Which is constructed > from a field in current table and if it's empty use a field from a associated > table. > > I used to use case when in my regular Rails requests. > > items.joins('left join item_variations iv on iv.item_id=items.id'). > select('case when iv.item_photo_id is not null then iv.picked_at else > items.picked_at end as combined_picked_at') > Now I'm looking for a way to use similar technique in Sphinx. Is it possible? > > > -- > You received this message because you are subscribed to the Google Groups > "Thinking Sphinx" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at http://groups.google.com/group/thinking-sphinx. > For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "Thinking Sphinx" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/thinking-sphinx. For more options, visit https://groups.google.com/d/optout.
