Posted By

andyh on 10/18/06


data rails ruby migration

Versions (?)

Who likes this?

1 person have marked this snippet as a favorite


Create data during migration

 / Published in: Ruby

  1. # e.g. Copy existing data from users table to newly created members table
  2. userMove = User.find(:all)
  3. userMove.each do |t|
  4. Member.create :first_name => t.forename,
  5. :last_name => t.surname,
  6. :email =>,
  7. :password => t.password
  8. end

Report this snippet  


RSS Icon Subscribe to comments
Posted By: lisa47 on August 17, 2019

I think that you need to check out this post for some great research papr writing tips. Good luck

You need to login to post a comment.