* Initialize the hash table to empty. */
| 117 | * Initialize the hash table to empty. |
| 118 | */ |
| 119 | static void |
| 120 | build_hash_table(SetOpState *setopstate) |
| 121 | { |
| 122 | SetOp *node = (SetOp *) setopstate->ps.plan; |
| 123 | ExprContext *econtext = setopstate->ps.ps_ExprContext; |
| 124 | TupleDesc desc = ExecGetResultType(outerPlanState(setopstate)); |
| 125 | |
| 126 | Assert(node->strategy == SETOP_HASHED); |
| 127 | Assert(node->numGroups > 0); |
| 128 | |
| 129 | setopstate->hashtable = BuildTupleHashTableExt(&setopstate->ps, |
| 130 | desc, |
| 131 | node->numCols, |
| 132 | node->dupColIdx, |
| 133 | setopstate->eqfuncoids, |
| 134 | setopstate->hashfunctions, |
| 135 | node->dupCollations, |
| 136 | node->numGroups, |
| 137 | 0, |
| 138 | setopstate->ps.state->es_query_cxt, |
| 139 | setopstate->tableContext, |
| 140 | econtext->ecxt_per_tuple_memory, |
| 141 | false); |
| 142 | } |
| 143 | |
| 144 | /* |
| 145 | * We've completed processing a tuple group. Decide how many copies (if any) |
no test coverage detected