The original implementation of polymorphic aggregates didn't really get the
Tom Lane <tgl@sss.pgh.pa.us>
The original implementation of polymorphic aggregates didn't really get the checking of argument compatibility right; although the problem is only exposed with multiple-input aggregates in which some arguments are polymorphic and some are not. Per bug #3852 from Sokolov Yura.
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/catalog/pg_aggregate.c | modified | +9 −20 |
| src/backend/executor/nodeAgg.c | modified | +3 −2 |
| src/backend/optimizer/util/clauses.c | modified | +3 −2 |
| src/backend/parser/parse_coerce.c | modified | +35 −26 |
| src/backend/parser/parse_func.c | modified | +3 −2 |
| src/backend/parser/parse_oper.c | modified | +5 −3 |
| src/include/parser/parse_coerce.h | modified | +3 −2 |
| src/test/regress/expected/polymorphism.out | modified | +36 −0 |
| src/test/regress/sql/polymorphism.sql | modified | +36 −0 |