From 2ac78b16df639bd02d4d70bcc672e1982fcb0877 Mon Sep 17 00:00:00 2001 From: Akshay Birajdar Date: Mon, 20 Sep 2021 12:19:34 +0530 Subject: [PATCH] Add `bigint` to `NATIVE_DATABASE_TYPES` in mysql & postgres adapter --- .../active_record/connection_adapters/abstract_mysql_adapter.rb | 1 + .../lib/active_record/connection_adapters/postgresql_adapter.rb | 1 + 2 files changed, 2 insertions(+) diff --git a/activerecord/lib/active_record/connection_adapters/abstract_mysql_adapter.rb b/activerecord/lib/active_record/connection_adapters/abstract_mysql_adapter.rb index 090c480e4b..2dc9fb2513 100644 --- a/activerecord/lib/active_record/connection_adapters/abstract_mysql_adapter.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract_mysql_adapter.rb @@ -31,6 +31,7 @@ module ActiveRecord string: { name: "varchar", limit: 255 }, text: { name: "text" }, integer: { name: "int", limit: 4 }, + bigint: { name: "bigint" }, float: { name: "float", limit: 24 }, decimal: { name: "decimal" }, datetime: { name: "datetime" }, diff --git a/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb b/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb index 354d2eeb97..74b36e21ae 100644 --- a/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb +++ b/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb @@ -125,6 +125,7 @@ module ActiveRecord string: { name: "character varying" }, text: { name: "text" }, integer: { name: "integer", limit: 4 }, + bigint: { name: "bigint" }, float: { name: "float" }, decimal: { name: "decimal" }, datetime: {}, # set dynamically based on datetime_type