added indexes
This commit is contained in:
@@ -12,6 +12,7 @@ class CreateWikiPages < ActiveRecord::Migration
|
||||
add_index :wiki_pages, :title, :unique => true
|
||||
execute "CREATE INDEX index_wiki_pages_on_body_index_index ON wiki_pages USING GIN (body_index)"
|
||||
execute "CREATE TRIGGER trigger_wiki_pages_on_update BEFORE INSERT OR UPDATE ON wiki_pages FOR EACH ROW EXECUTE PROCEDURE tsvector_update_trigger('body_index', 'public.danbooru', 'body', 'title')"
|
||||
execute "create index index_wiki_pages_on_title_pattern on wiki_pages (title text_pattern_ops)"
|
||||
end
|
||||
|
||||
def self.down
|
||||
|
||||
Reference in New Issue
Block a user