On Thu, Nov 23, 2006 at 11:28:45AM +0100, Matthew Planchant wrote:
> OK. Here is what is happening. When the indexing starts it selects the 
> first 1000 records to add to the index. These seem to be added to the 
> index. When it has added the 1000th record another select appears in the 
> log file to get the rest of records (There are 1561 records in the 
> table):
> 
> 
> SELECT * FROM (SELECT TOP 561 * FROM (SELECT TOP 1561 * FROM persons) AS 
> tmp1 ) AS tmp2

ehm, what kind of database is this ? looks really strange ;-)
 
> However this select doesn't get the records from 1001 to 1561. It get 1 
> to 1000. So these first 500 or so records are added to the index twice 
> but the final 500 are never added.

is it possible the :limit and :offset options of ActiveRecord are not
supported or buggy for your kind of database ?

what do you get when calling 
Person.find(:all, :limit => 1000, :offset => 1000) 
on the console ?


Jens
 

-- 
webit! Gesellschaft für neue Medien mbH          www.webit.de
Dipl.-Wirtschaftsingenieur Jens Krämer       [EMAIL PROTECTED]
Schnorrstraße 76                         Tel +49 351 46766  0
D-01069 Dresden                          Fax +49 351 46766 66
_______________________________________________
Ferret-talk mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/ferret-talk

Reply via email to