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.5.27 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.5.26 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.5.25 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.5.24 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.5.23 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.5.22 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.5.21 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.5.20 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.5.19 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.5.18 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.5.17 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.5.16 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.5.15 db/migrate/20091109012126_add_missing_indexes.rb
refinerycms-0.9.5.14 db/migrate/20091109012126_add_missing_indexes.rb