rosa-build/db/migrate/20130731120901_create_proje...

14 lines
448 B
Ruby

class CreateProjectStatistics < ActiveRecord::Migration
def change
create_table :project_statistics do |t|
t.integer :average_build_time, null: false, default: 0
t.integer :build_count, null: false, default: 0
t.integer :arch_id, null: false
t.integer :project_id, null: false
t.timestamps
end
add_index :project_statistics, [:project_id, :arch_id], unique: true
end
end