diff options
author | Santiago Pastorino <santiago@wyeworks.com> | 2010-07-22 13:00:29 -0300 |
---|---|---|
committer | Santiago Pastorino <santiago@wyeworks.com> | 2010-07-22 15:49:05 -0300 |
commit | 24f303b677e4a8f0ecf8c335d95c63c3f7f1bdcc (patch) | |
tree | 27460648aa2dfbad316c7d4957a0cf8da0fc3c6e /activerecord/lib | |
parent | 7113f207c34e41ffcbbd0b3570f3fe41bbfbbcaf (diff) | |
download | rails-24f303b677e4a8f0ecf8c335d95c63c3f7f1bdcc.tar.gz rails-24f303b677e4a8f0ecf8c335d95c63c3f7f1bdcc.tar.bz2 rails-24f303b677e4a8f0ecf8c335d95c63c3f7f1bdcc.zip |
Makes current adapter decide the syntax of PRIMARY KEY column definition
Diffstat (limited to 'activerecord/lib')
-rw-r--r-- | activerecord/lib/active_record/session_store.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/session_store.rb b/activerecord/lib/active_record/session_store.rb index bd976acdbb..365fcd6222 100644 --- a/activerecord/lib/active_record/session_store.rb +++ b/activerecord/lib/active_record/session_store.rb @@ -82,7 +82,7 @@ module ActiveRecord def create_table! connection.execute <<-end_sql CREATE TABLE #{table_name} ( - id INTEGER PRIMARY KEY, + id #{connection.type_to_sql(:primary_key)}, #{connection.quote_column_name(session_id_column)} VARCHAR(255) UNIQUE, #{connection.quote_column_name(data_column_name)} VARCHAR(255) ) @@ -219,7 +219,7 @@ module ActiveRecord def create_table! connection.execute <<-end_sql CREATE TABLE #{table_name} ( - id INTEGER PRIMARY KEY, + id #{connection.type_to_sql(:primary_key)}, #{connection.quote_column_name(session_id_column)} VARCHAR(255) UNIQUE, #{connection.quote_column_name(data_column)} TEXT ) |