Hi,

I have an index like so:

class Car

has :score
has :manufacturer_id

end

What I'm trying to achieve is groups of cars by manufacturer id sorted
by the maximum possible score for each group.

SQL equivalent: select *, max(score) as max_score from cars group by
manufacturer_id order by max_score DESC;

With Sphinx:
Car.search(:group_by=>:manufacturer_id, :group_function=>:attr, 
:group_clause=>"score
DESC") obviously doesn't return what I want to see.

Help :)

Cheers,
Sid.

-- 
You received this message because you are subscribed to the Google Groups 
"Thinking Sphinx" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/thinking-sphinx?hl=en.

Reply via email to