Sha256: 62c1342f0337fefb5894be6177908c4f783403b7b1fe6f7a684c8b15c4323fd3

Contents?: true

Size: 359 Bytes

Versions: 2

Compression:

Stored size: 359 Bytes

Contents

class CreateRelationships < ActiveRecord::Migration
  def change
    create_table :relationships do |t|
      t.integer :follower_id
      t.integer :followed_id

      t.timestamps
    end

    add_index :relationships, :follower_id
    add_index :relationships, :followed_id
    add_index :relationships, [:follower_id, :followed_id], unique: true
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
guara-0.0.3 db/migrate/20120617224530_create_relationships.rb
guara-0.0.1.rc db/migrate/20120617224530_create_relationships.rb