OSDN Git Service

6fcb8ab7b92fa7cda7d398b2488763a4dcd9cf84
[mint/mint-server.git] / db / migrate / 20091215064720_create_users.rb
1 class CreateUsers < ActiveRecord::Migration
2   def self.up
3     create_table :users do |t|
4       t.integer :affiliation_id, :null => true
5       t.string :matriculation_number, :null => true, :limit => 100
6       t.string :name,  :null => true, :limit => 200
7       t.string :email, :null => true, :limit => 200
8       t.date :admission_date, :null => true
9
10       t.timestamps
11       t.integer :lock_version, :null => false, :default => 0
12     end
13   end
14
15   def self.down
16     drop_table :users
17   end
18 end