Sha256: e2a7c8ac8be2f8ee44ffa7554af92927fcec0c37c80ea84e11695091706365ac
Contents?: true
Size: 493 Bytes
Versions: 6
Compression:
Stored size: 493 Bytes
Contents
class AddIndexOnCategories < ActiveRecord::Migration def self.up add_index :categories_elements, [:category_id, :element_id], :unique => true change_column :categories, :type, :string, :limit => 45 add_index :categories, [:id, :type], :unique => true end def self.down remove_index :categories_elements, :column => [:category_id, :element_id] remove_index :categories, :column => [:id, :type] change_column :categories, :type, :string, :limit => 255 end end
Version data entries
6 entries across 6 versions & 1 rubygems