1 class CreatePosts < ActiveRecord::Migration
3 create_table :posts do |t|
4 t.column "poster", :string, :limit => 200, :default => "", :null => false
5 t.column "poster_id", :integer, :limit => 10, :default => 1, :null => false
6 t.column "poster_ip", :string, :limit => 15
7 t.column "poster_email", :string, :limit => 50
8 t.column "message", :text, :default => "", :null => false
9 t.column "hide_smilies", :boolean, :default => false, :null => false
10 t.column "edited_by", :string, :limit => 200
11 t.column "topic_id", :integer, :limit => 10, :default => 0, :null => false
12 t.column "created_at", :timestamp, :limit => 14
13 t.column "updated_at", :timestamp, :limit => 14
15 add_index "posts", ["topic_id"], :name => "posts_topic_id_idx"
16 add_index "posts", ["poster_id", "topic_id"], :name => "posts_multi_idx"