mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Address ORA-00923 error by quoting a reserved word "SIZE"
This commit is contained in:
parent
39e087cbf5
commit
8a4a8b2aca
1 changed files with 1 additions and 1 deletions
|
@ -16,7 +16,7 @@ module ActiveRecord
|
|||
|
||||
query = collection
|
||||
.unscope(:select)
|
||||
.select("COUNT(*) AS size", "MAX(#{column}) AS timestamp")
|
||||
.select("COUNT(*) AS #{connection.quote_column_name("size")}", "MAX(#{column}) AS timestamp")
|
||||
.unscope(:order)
|
||||
result = connection.select_one(query)
|
||||
|
||||
|
|
Loading…
Reference in a new issue