Sha256: b4f06d5ae72a4bb94ad88ae89312521343e63ce8c0c9b46fa2d108eb54a0bfd3

Contents?: true

Size: 506 Bytes

Versions: 43

Compression:

Stored size: 506 Bytes

Contents

ActiveRecord::Schema.define do
  connection.tables.each do |table| drop_table table end

  create_table :users, :force => true do |t|
    t.string :login, :index => { :unique => true }
  end

  create_table :members, :force => true do |t|
    t.string :login
  end
  
  create_table :comments, :force => true do |t|
    t.string :content
    t.integer :user
    t.integer :user_id
    t.foreign_key :user_id, :users, :id
  end

  create_table :posts, :force => true do |t|
    t.string :content
  end

end

Version data entries

43 entries across 43 versions & 1 rubygems

Version Path
schema_plus-1.8.6 spec/schema/auto_schema.rb
schema_plus-1.8.5 spec/schema/auto_schema.rb
schema_plus-1.8.4 spec/schema/auto_schema.rb
schema_plus-1.8.3 spec/schema/auto_schema.rb
schema_plus-1.8.2 spec/schema/auto_schema.rb
schema_plus-1.8.1 spec/schema/auto_schema.rb
schema_plus-1.8.0 spec/schema/auto_schema.rb
schema_plus-1.7.1 spec/schema/auto_schema.rb
schema_plus-1.7.0 spec/schema/auto_schema.rb
schema_plus-1.6.0 spec/schema/auto_schema.rb
schema_plus-1.5.3 spec/schema/auto_schema.rb
schema_plus-1.5.2 spec/schema/auto_schema.rb
schema_plus-1.5.1 spec/schema/auto_schema.rb
schema_plus-1.5.0 spec/schema/auto_schema.rb
schema_plus-1.4.1 spec/schema/auto_schema.rb
schema_plus-1.4.0 spec/schema/auto_schema.rb
schema_plus-1.3.3 spec/schema/auto_schema.rb
schema_plus-1.3.2 spec/schema/auto_schema.rb
schema_plus-1.3.1 spec/schema/auto_schema.rb
schema_plus-1.3.0 spec/schema/auto_schema.rb