1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Should be sync the primary_key definition with actually created

Actually the `primary_key` definition is not used but the inconsistency
is confusing. Actual definition is `bigint auto_increment PRIMARY KEY`
so `UNSIGNED` and `(8)` is unnecessary.

See also #21607.
This commit is contained in:
Ryuta Kamizono 2016-12-06 09:27:04 +09:00
parent 9b6f312734
commit 6be6374403

View file

@ -39,7 +39,7 @@ module ActiveRecord
self.emulate_booleans = true
NATIVE_DATABASE_TYPES = {
primary_key: "BIGINT(8) UNSIGNED auto_increment PRIMARY KEY",
primary_key: "bigint auto_increment PRIMARY KEY",
string: { name: "varchar", limit: 255 },
text: { name: "text", limit: 65535 },
integer: { name: "int", limit: 4 },