Skip to content

Commit a9fbb04

Browse files
authored
Aggregate value should be true for any_value operator (#61)
* aggregate value should be true for any_value operatore * Update gemfile.lock
1 parent 9229830 commit a9fbb04

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

Gemfile.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: .
33
specs:
4-
query_helper (0.4.2)
4+
query_helper (0.4.4)
55
activerecord (> 5)
66
activesupport (> 5)
77
sqlite3

lib/query_helper/sql_parser.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ def find_aliases
188188
ColumnMap.new(
189189
alias_name: sql_alias,
190190
sql_expression: sql_expression.squish,
191-
aggregate: /\b(array_agg|avg|bit_and|bit_or|bool_and|bool_or|boolor_agg|booland_agg|count|every|json_agg|jsonb_agg|json_object_agg|jsonb_object_agg|max|min|string_agg|sum|xmlagg)\((.*)\)/.match?(sql_expression)
191+
aggregate: /\b(array_agg|avg|bit_and|bit_or|bool_and|bool_or|boolor_agg|booland_agg|count|every|json_agg|jsonb_agg|json_object_agg|jsonb_object_agg|max|min|string_agg|sum|xmlagg|any_value|ANY_VALUE)\((.*)\)/.match?(sql_expression)
192192
) if sql_alias
193193
end
194194
column_maps.compact

lib/query_helper/version.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
class QueryHelper
2-
VERSION = "0.4.3"
2+
VERSION = "0.4.4"
33
end

0 commit comments

Comments
 (0)