diff --git a/db/migrate/20140526093613_add_userstamps_to_versions.rb b/db/migrate/20140526093613_add_userstamps_to_versions.rb index c6a2d04..629e1d6 100644 --- a/db/migrate/20140526093613_add_userstamps_to_versions.rb +++ b/db/migrate/20140526093613_add_userstamps_to_versions.rb @@ -2,5 +2,7 @@ class AddUserstampsToVersions < ActiveRecord::Migration def change add_column :versions, :creator_id, :integer add_column :versions, :updator_id, :integer + add_index :versions, :creator_id + add_index :versions, :updator_id end end diff --git a/db/schema.rb b/db/schema.rb index bae4bfc..71bf421 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -181,6 +181,8 @@ ActiveRecord::Schema.define(version: 20140526093613) do t.integer "updator_id" end + add_index "versions", ["creator_id"], name: "index_versions_on_creator_id", using: :btree add_index "versions", ["item_type", "item_id"], name: "index_versions_on_item_type_and_item_id", using: :btree + add_index "versions", ["updator_id"], name: "index_versions_on_updator_id", using: :btree end