diff options
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/031_add_indices_for_session_deletion.rb | 9 | ||||
-rw-r--r-- | db/schema.rb | 3 |
2 files changed, 11 insertions, 1 deletions
diff --git a/db/migrate/031_add_indices_for_session_deletion.rb b/db/migrate/031_add_indices_for_session_deletion.rb new file mode 100644 index 000000000..9a6f6b326 --- /dev/null +++ b/db/migrate/031_add_indices_for_session_deletion.rb @@ -0,0 +1,9 @@ +class AddIndicesForSessionDeletion < ActiveRecord::Migration + def self.up + add_index :post_redirects, :updated_at + end + + def self.down + remove_index :post_redirects, :updated_at + end +end diff --git a/db/schema.rb b/db/schema.rb index 07e62f893..72e075da7 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -9,7 +9,7 @@ # # It's strongly recommended to check this file into your version control system. -ActiveRecord::Schema.define(:version => 30) do +ActiveRecord::Schema.define(:version => 31) do create_table "incoming_messages", :force => true do |t| t.integer "info_request_id", :null => false @@ -64,6 +64,7 @@ ActiveRecord::Schema.define(:version => 30) do add_index "post_redirects", ["email_token"], :name => "index_post_redirects_on_email_token" add_index "post_redirects", ["token"], :name => "index_post_redirects_on_token" + add_index "post_redirects", ["updated_at"], :name => "index_post_redirects_on_updated_at" create_table "public_bodies", :force => true do |t| t.text "name", :null => false |