Ticket #10740: find_conditions_field_with_array_rdoc_patch.diff
| File find_conditions_field_with_array_rdoc_patch.diff, 1.2 kB (added by kris_chambers, 9 months ago) |
|---|
-
activerecord/lib/active_record/base.rb
old new 191 191 # 192 192 # Student.find(:all, :conditions => { :grade => 9..12 }) 193 193 # 194 # An array may be used in the hash to use the SQL IN operator: 195 # 196 # Student.find(:all, :conditions => { :grade => [9,11,12] }) 197 # 194 198 # == Overwriting default accessors 195 199 # 196 200 # All column values are automatically available through basic accessors on the Active Record object, but sometimes you … … 478 482 # Examples for find all: 479 483 # Person.find(:all) # returns an array of objects for all the rows fetched by SELECT * FROM people 480 484 # Person.find(:all, :conditions => [ "category IN (?)", categories], :limit => 50) 481 # Person.find(:all, :offset => 10, :limit => 10) 485 # Person.find(:all, :conditions => { :friends => ["Bob", "Steve", "Fred"] } 486 # Person.find(:all, :offset => 10, :limit => 10) 482 487 # Person.find(:all, :include => [ :account, :friends ]) 483 488 # Person.find(:all, :group => "category") 484 489 #