Jens Kraemer wrote:
> On Fri, May 18, 2007 at 07:53:39PM +0200, Jon Druse wrote:
>> here's my search mothod ...
>>
>>
>> @results = Record.multi_search(params[:search_terms], [ Link, Post
>> ], {:limit => :all})
>
> the :sort option belongs to the same hash as :limit.
>
> here's a sample from the aaf unit tests:
>
> sorting = [ Ferret::Search::SortField.new(:id) ]
> result = Content.multi_search('*:title OR *:comment',
> [Comment],
> :sort => sorting)
>
> note that I don't use the Sort class at all, an Array of SortFields is
> ok.
sorry i'm so lame... i though we were sorting by score? my results
don't seem to change when i put that in there. :-)
Jon
--
Posted via http://www.ruby-forum.com/.
_______________________________________________
Ferret-talk mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/ferret-talk