Ever since updating to TS 1.2.x there is the problem that (likely) the
Pagination is not respecting the max_matches modifier.

Example: I want to query max_matches 300 in a set with 6000 records

    Model.search(
         (""),
         :page => (params[:page] || 1),
         :per_page => 30,
         :max_matches => 300,
       )

In my result view i now unexpectatly see pagination links  for all
available 6000 records (200 Pages). Clicking on the page-link for page
11 (which would be results 301-330), i get an error:

searchd error (status: 1): offset out of bounds (offset=300,
max_matches=300)

This is a  correct behaviour since i have not requested more than 300
results in the first place. So the actual querying seems to be just
fine, but when preparing the collection for will_paginate, there seems
to be a problem or something has changed that I need to modify.

My Pagination-Call in the view has not changed ever since:

        <%= will_paginate(@results,
                                :previous_label => '<!-- -->',
                                :next_label => '<!-- -->') %>

Greets
-act




--~--~---------~--~----~------------~-------~--~----~
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