ActiveRecord: reducing memory footprint with find

Hi, My script that uses ActiveRecord to retreive about 1mil of records from database runs out of memory in about 10 second and crashes. Is there any way to significantly reduce memory footprint? The line in question is a simple object.find(:all, :conditions => "..........")

Help would be much appreciated. Thanks Petr

Hi, My script that uses ActiveRecord to retreive about 1mil of records
from database runs out of memory in about 10 second and crashes. Is there
any way to significantly reduce memory footprint? The line in question
is a simple object.find(:all, :conditions => "..........")

Well using :select to only fetch needed columns would help. I would
expect that dropping down to the level of
ActiveRecord::Base.connection.select_all would save you something as
well, but obviously you're not dealing with ActiveRecord objects
anymore.

Fred