* Advance each aggregate transition state for one input tuple. The input * tuple has been stored in tmpcontext->ecxt_outertuple, so that it is * accessible to ExecEvalExpr. * * We have two sets of transition states to handle: one for sorted aggregation * and one for hashed; we do them both here, to avoid multiple evaluation of * the inputs. * * When called, CurrentMemoryContext should be
| 853 | * When called, CurrentMemoryContext should be the per-query context. |
| 854 | */ |
| 855 | static void |
| 856 | advance_aggregates(AggState *aggstate) |
| 857 | { |
| 858 | bool dummynull; |
| 859 | |
| 860 | ExecEvalExprSwitchContext(aggstate->phase->evaltrans, |
| 861 | aggstate->tmpcontext, |
| 862 | &dummynull); |
| 863 | } |
| 864 | |
| 865 | /* |
| 866 | * Run the transition function for a DISTINCT or ORDER BY aggregate |
no test coverage detected