Ruby on Rails: Get some random records
Nov 30 2009
EDIT AGAIN: Much better.. To get a 'num_reqd' array of random objects, you can use something like this. named_scope :large, :conditions => ['image_file_name IS NOT ...