Sha256: ea9403145d570271684ed30074c051798253bbdd403a64770576189df024537f

Contents?: true

Size: 476 Bytes

Versions: 7

Compression:

Stored size: 476 Bytes

Contents

class RenameCardMigrationTable < ActiveRecord::Migration
  def self.up
    if ActiveRecord::Base.connection.table_exists? :schema_migrations_cards
      rename_table :schema_migrations_cards, :schema_migrations_core_cards
    else
      create_table 'schema_migrations_core_cards', id: false, force: true do |t|
        t.string 'version', null: false
      end
    end
  end

  def self.down
    rename_table :schema_migrations_core_cards, :schema_migrations_cards
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
card-1.18.6 db/migrate/20141121172918_rename_card_migration_table.rb
card-1.18.5 db/migrate/20141121172918_rename_card_migration_table.rb
card-1.18.4 db/migrate/20141121172918_rename_card_migration_table.rb
card-1.18.3 db/migrate/20141121172918_rename_card_migration_table.rb
card-1.18.2 db/migrate/20141121172918_rename_card_migration_table.rb
card-1.18.1 db/migrate/20141121172918_rename_card_migration_table.rb
card-1.18.0 db/migrate/20141121172918_rename_card_migration_table.rb