Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #1702 from brianmario/lazy-mysql2-casting

Turn off mysql2's eager-casting
  • Loading branch information...
commit 5daef25f0ab219cb11efb48eec173159f76b2168 2 parents 78587a5 + aeb7beb
@josevalim josevalim authored
View
2  Gemfile
@@ -55,7 +55,7 @@ platforms :ruby do
group :db do
gem "pg", ">= 0.11.0"
gem "mysql", ">= 2.8.1"
- gem "mysql2", ">= 0.3.0"
+ gem "mysql2", ">= 0.3.3"
end
end
View
4 activerecord/lib/active_record/connection_adapters/mysql2_adapter.rb
@@ -1,6 +1,6 @@
# encoding: utf-8
-gem 'mysql2', '~> 0.3.0'
+gem 'mysql2', '~> 0.3.3'
require 'mysql2'
module ActiveRecord
@@ -629,7 +629,7 @@ def connect
end
def configure_connection
- @connection.query_options.merge!(:as => :array)
+ @connection.query_options.merge!(:as => :array, :cast => false)
# By default, MySQL 'where id is null' selects the last inserted id.
# Turn this off. http://dev.rubyonrails.org/ticket/6778
Please sign in to comment.
Something went wrong with that request. Please try again.