How do i do an “update posts set home
=1” with ActiveRecord?
sorry. a peek into the API gave me the solution.
Post.update_all(:home=>1)
How do i do an “update posts set home
=1” with ActiveRecord?
sorry. a peek into the API gave me the solution.
Post.update_all(:home=>1)
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.
Sponsor our Newsletter | Privacy Policy | Terms of Service | Remote Ruby Jobs