diff options
author | david <david@nlpgo.com> | 2018-05-28 12:11:57 +0200 |
---|---|---|
committer | david <david@nlpgo.com> | 2018-05-28 12:11:57 +0200 |
commit | bbe3e7f298c1b99724f9b4c3b3cbc8778b210342 (patch) | |
tree | badf3f74fc0c81de56406d7cdd72cbc8e1d44df3 /activerecord/lib | |
parent | 36390b6bdc75fca70e7a9d74c6270e3f40e77799 (diff) | |
download | rails-bbe3e7f298c1b99724f9b4c3b3cbc8778b210342.tar.gz rails-bbe3e7f298c1b99724f9b4c3b3cbc8778b210342.tar.bz2 rails-bbe3e7f298c1b99724f9b4c3b3cbc8778b210342.zip |
Fix: Arel Postgresql visitor generates invalid SQL for GROUPING SETS.
Diffstat (limited to 'activerecord/lib')
-rw-r--r-- | activerecord/lib/arel/visitors/postgresql.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/lib/arel/visitors/postgresql.rb b/activerecord/lib/arel/visitors/postgresql.rb index 108ee431ee..c5110fa89c 100644 --- a/activerecord/lib/arel/visitors/postgresql.rb +++ b/activerecord/lib/arel/visitors/postgresql.rb @@ -5,7 +5,7 @@ module Arel # :nodoc: all class PostgreSQL < Arel::Visitors::ToSql CUBE = "CUBE" ROLLUP = "ROLLUP" - GROUPING_SET = "GROUPING SET" + GROUPING_SETS = "GROUPING SETS" LATERAL = "LATERAL" private @@ -67,7 +67,7 @@ module Arel # :nodoc: all end def visit_Arel_Nodes_GroupingSet(o, collector) - collector << GROUPING_SET + collector << GROUPING_SETS grouping_array_or_grouping_element o, collector end |