title: Migrating data with rake db:migrate does not change it
body: <p>I am struggling with rails and db:migrate. I have a migration with this code</p>
  
  <pre><code>class SetDefaultInstallmentsForLicenses &lt; ActiveRecord::Migration
    def up
      License.where(code: 'LEADER').each do |leader|
        puts "Modifying license #{leader.id} with code #{leader.code}"
        leader.installment_available = true
        leader.installment_number = 5
        leader.save
        puts "After save #{leader.installment_available} #{leader.installment_number}"
        leader = License.find(leader.id)
        puts "After save #{leader.installment_available} #{leader.installment_number}"
      end
    end
  
    def down
    end
  end
  </code></pre>
  
  <p>After running the migration there is this output</p>
  
  <pre><code>==  SetDefaultInstallmentsForLicenses: migrating ==============================
  Modifying license 3 with code LEADER
  After save true 5
  After save f
  ==  SetDefaultInstallmentsForLicenses: migrated (0.0037s) =====================
  </code></pre>
  
  <p>It's clearly visible that the migration was executed, record was found, changed and saved, but after  reloading the record, the changes are not there.
  What's wrong?</p>