Permalink
Browse files

don't quote decimal values for mysql. It doesn't make sense and break…

…s in newer versions of mysql

Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#1168 state:committed]
  • Loading branch information...
1 parent 2def5b6 commit 4cb3d27443fa30fde528f07658e76537f38a0661 Aliaksey Kandratsenka committed with NZKoz Sep 6, 2008
Showing with 1 addition and 1 deletion.
  1. +1 −1 activerecord/lib/active_record/connection_adapters/mysql_adapter.rb
@@ -218,7 +218,7 @@ def quote(value, column = nil)
s = column.class.string_to_binary(value).unpack("H*")[0]
"x'#{s}'"
elsif value.kind_of?(BigDecimal)
- "'#{value.to_s("F")}'"
+ value.to_s("F")
else
super
end

0 comments on commit 4cb3d27

Please sign in to comment.