From 27f8c57f5f88304212a00cb8e32f8227755a7265 Mon Sep 17 00:00:00 2001 From: Aaron Patterson Date: Wed, 13 Apr 2011 15:34:08 -0700 Subject: inserting big decimals as strings works consistently among dbs, so use string form --- activerecord/lib/active_record/connection_adapters/abstract/quoting.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'activerecord/lib/active_record/connection_adapters') diff --git a/activerecord/lib/active_record/connection_adapters/abstract/quoting.rb b/activerecord/lib/active_record/connection_adapters/abstract/quoting.rb index 5634e53e80..3de850ec9e 100644 --- a/activerecord/lib/active_record/connection_adapters/abstract/quoting.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract/quoting.rb @@ -66,7 +66,7 @@ module ActiveRecord end # BigDecimals need to be put in a non-normalized form and quoted. when nil then nil - when BigDecimal then value.to_f + when BigDecimal then value.to_s('F') when Numeric then value when Date, Time then quoted_date(value) when Symbol then value.to_s -- cgit v1.2.3