Add indexes to Dossier.state, Dossier.archived, Follow.unfollowed_at
We make a ton of queries on these attributes (for example in /procedures#index and /procedures#show). I think it should help.
This commit is contained in:
parent
1505d45be1
commit
780e157190
2 changed files with 11 additions and 1 deletions
7
db/migrate/20190920122228_add_indexes_to_dossier.rb
Normal file
7
db/migrate/20190920122228_add_indexes_to_dossier.rb
Normal file
|
@ -0,0 +1,7 @@
|
|||
class AddIndexesToDossier < ActiveRecord::Migration[5.2]
|
||||
def change
|
||||
add_index :dossiers, :state
|
||||
add_index :dossiers, :archived
|
||||
add_index :follows, :unfollowed_at
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue