What do you mean saying &quot;more thoroughly&quot;. This is code from my application and it works great.<br><br>&nbsp;&nbsp;&nbsp; page_num = @params['page'] ? @params['page'].to_i : 1<br>&nbsp;&nbsp;  <br>&nbsp;&nbsp;&nbsp; total_hits = index.search_each(query, :num_docs =&gt; PAGE_SIZE, :first_doc =&gt; PAGE_SIZE*(page_num-1)) do |doc_num, score|
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; @documents &lt;&lt; index[doc_num]<br>&nbsp;&nbsp;&nbsp; end<br><br>&nbsp;&nbsp;&nbsp; @document_pages = Paginator.new self, total_hits, PAGE_SIZE, page_num<br><br>Is it makes sense to put it to &quot;HowTos&quot; page??<br><br><br><div><span class="gmail_quote">
On 12/2/05, <b class="gmail_sendername">Carl Youngblood</b> &lt;<a href="mailto:carl@youngbloods.org">carl@youngbloods.org</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
No doubt I just needed to scour the documentation more thoroughly, but<br>thanks for the help.<br><br>Carl<br><br>On 12/1/05, David Balmain &lt;<a href="mailto:dbalmain.ml@gmail.com">dbalmain.ml@gmail.com</a>&gt; wrote:<br>
&gt; Hi Carl,<br>&gt;<br>&gt; This is easy. If you use the search method (not search_each) a TopDocs<br>&gt; object is returned which has the attribute total hits. Or you can<br>&gt; continue to use the search_each method like this;
<br>&gt;<br>&gt; total_hits = index.search_each(&quot;query&quot;) {|doc, score| puts &quot;doc&quot;}<br>&gt;<br>&gt; Hope this helps,<br>&gt; Dave<br><br>_______________________________________________<br>Ferret-talk mailing list
<br><a href="mailto:Ferret-talk@rubyforge.org">Ferret-talk@rubyforge.org</a><br><a href="http://rubyforge.org/mailman/listinfo/ferret-talk">http://rubyforge.org/mailman/listinfo/ferret-talk</a><br></blockquote></div><br><br clear="all">
<br>-- <br>anatol (<a href="http://pomozov.info">http://pomozov.info</a>)