From: Mike Harris Date: 2007-02-07T01:55:36+09:00 Subject: Re: Database migration Jerry Jones wrote: > Beginner alert..... > I am working on a database migration. I am adding inventory items to > the table. I have the data, but for the life of me, I cannot remember > where to make this file. I remember how to run the migration etc. > So where do I put the > > class AddUserTable < ActiveRecord::Migration > def self.up > create_table :users do |table| > table.column :name, :string > table.column :login, :string > table.column :password, :string, :limit => 32 > table.column :email, :string > end > end > > def self.down > drop_table :users > end > end > > The db\migrate folder. Make a migration with ruby script\generate migration AddUserTable. Read the docs (http://api.rubyonrails.com) and please direct further questions to the Rails mailing list.