以下は、PostgreSQLの例。 ActiveRecord::ConnectionAdapters::PostgreSQLAdapter::NATIVEDATABASETYPES[:primary_key] = ‘bigserial primary key’ 外部キーの場合、t.references :userとか書いてると、ActiveRecord側でintegerがハードコーディングされているのでlimitオプションを付けるしかなさそう。 t.references :user, :limit => 8