Sha256: 1904dae5230119973613762840dee2d6c2476364bcab89edc4608d6708d6db41

Contents?: true

Size: 649 Bytes

Versions: 74

Compression:

Stored size: 649 Bytes

Contents

class AddMissingIndexes < ActiveRecord::Migration
  def self.up
    add_index :pages, :parent_id
    add_index :pages, :custom_title_image_id
    add_index :pages, :image_id
    add_index :images, :parent_id
    add_index :page_parts, :page_id

    add_index :pages, :id
    add_index :page_parts, :id
    add_index :users, :id
  end

  def self.down
    remove_index :pages, :parent_id
    remove_index :pages, :custom_title_image_id
    remove_index :pages, :image_id
    remove_index :images, :parent_id
    remove_index :page_parts, :page_id

    remove_index :pages, :id
    remove_index :page_parts, :id
    remove_index :users, :id
  end
end

Version data entries

74 entries across 74 versions & 2 rubygems

Version Path
refinerycms-0.9.7.15 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.7.14 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.8.5 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.8.4 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.8.3 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.8.2 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.8.1 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.8 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.7.13 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.7.11 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.7.10 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.7.9 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.7.8 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.7.7 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.7.6 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.7.5 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.7.4 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.7.3 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.7.2 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.7.1 db/migrate/20091109012126_add_missing_indexes.rb