Limit number of results from dynamic finders


#1

Hi everyone,
I’m looking for a way to limit the number of results returned by the
select genereted when I use the following syntax:
User.posts.each { |post| … }

I’m not sure those are dynamic finders per se, but I’m not familier with
the correct term. any way, I’d like to only select the first 5 posts
withut using find_by_sql or find(:all, :limit => 5).

Is that possible?

Thanks,
Ehud