Permalink
Browse files

improve example in migrations docs, closes #6370

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5275 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
1 parent 02dc646 commit f65ab3b233e112679fc7a183b488c5356a01c96c @jeremy jeremy committed Oct 9, 2006
Showing with 2 additions and 2 deletions.
  1. +2 −2 activerecord/lib/active_record/migration.rb
@@ -157,7 +157,7 @@ def initialize(version)
# add_column :people, :salary, :integer
# Person.reset_column_information
# Person.find(:all).each do |p|
- # p.salary = SalaryCalculator.compute(p)
+ # p.update_attribute :salary, SalaryCalculator.compute(p)
# end
# end
# end
@@ -177,7 +177,7 @@ def initialize(version)
# ...
# say_with_time "Updating salaries..." do
# Person.find(:all).each do |p|
- # p.salary = SalaryCalculator.compute(p)
+ # p.update_attribute :salary, SalaryCalculator.compute(p)
# end
# end
# ...

0 comments on commit f65ab3b

Please sign in to comment.