diff options
author | kennyj <kennyj@gmail.com> | 2013-07-16 23:48:18 +0900 |
---|---|---|
committer | kennyj <kennyj@gmail.com> | 2013-07-23 02:05:49 +0900 |
commit | 42f4ec62657efb002aa550ed4be6099ef13a6d50 (patch) | |
tree | 2780dfb70f175379c06ce12a22469a31b13cd465 /activerecord/lib | |
parent | 68bbbd470dd9439c03411e3b83ad4361d5e82730 (diff) | |
download | rails-42f4ec62657efb002aa550ed4be6099ef13a6d50.tar.gz rails-42f4ec62657efb002aa550ed4be6099ef13a6d50.tar.bz2 rails-42f4ec62657efb002aa550ed4be6099ef13a6d50.zip |
Defines the return type of select / select_all method.
Diffstat (limited to 'activerecord/lib')
-rw-r--r-- | activerecord/lib/active_record/connection_adapters/abstract/database_statements.rb | 6 | ||||
-rw-r--r-- | activerecord/lib/active_record/connection_adapters/mysql2_adapter.rb | 3 |
2 files changed, 3 insertions, 6 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/abstract/database_statements.rb b/activerecord/lib/active_record/connection_adapters/abstract/database_statements.rb index c64b542286..3e79b71fb3 100644 --- a/activerecord/lib/active_record/connection_adapters/abstract/database_statements.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract/database_statements.rb @@ -18,8 +18,7 @@ module ActiveRecord end end - # Returns an array of record hashes with the column names as keys and - # column values as values. + # Returns an ActiveRecord::Result instance. def select_all(arel, name = nil, binds = []) select(to_sql(arel, binds), name, binds) end @@ -355,8 +354,7 @@ module ActiveRecord subselect end - # Returns an array of record hashes with the column names as keys and - # column values as values. + # Returns an ActiveRecord::Result instance. def select(sql, name = nil, binds = []) end undef_method :select diff --git a/activerecord/lib/active_record/connection_adapters/mysql2_adapter.rb b/activerecord/lib/active_record/connection_adapters/mysql2_adapter.rb index edeb338310..3ff4e535a4 100644 --- a/activerecord/lib/active_record/connection_adapters/mysql2_adapter.rb +++ b/activerecord/lib/active_record/connection_adapters/mysql2_adapter.rb @@ -229,8 +229,7 @@ module ActiveRecord alias exec_without_stmt exec_query - # Returns an array of record hashes with the column names as keys and - # column values as values. + # Returns an ActiveRecord::Result instance. def select(sql, name = nil, binds = []) exec_query(sql, name) end |