Sha256: fb00e5a77f270384f290da33b51bec82ad02cb1e5794ebb6383a18af1cc27c0b
Contents?: true
Size: 344 Bytes
Versions: 35
Compression:
Stored size: 344 Bytes
Contents
class CreateLocations < ActiveRecord::Migration def change create_table :locations do |t| t.string :name, null: false t.string :kind t.integer :parent_location_id, index: true, foreign_key: false t.timestamps null: false end add_index :locations, [:parent_location_id,:kind,:name], unique: true end end
Version data entries
35 entries across 35 versions & 2 rubygems