/* * ExecCQMatViewUpdate * * Update an existing row of a CV materialization table. */ void ExecCQMatRelUpdate(ResultRelInfo *ri, TupleTableSlot *slot, EState *estate) { HeapTuple tup = ExecMaterializeSlot(slot); simple_heap_update(ri->ri_RelationDesc, &tup->t_self, tup); ExecInsertCQMatRelIndexTuples(ri, slot, estate); }
/* * ExecCQMatViewInsert * * Insert a new row into a CV materialization table */ void ExecCQMatRelInsert(ResultRelInfo *ri, TupleTableSlot *slot, EState *estate) { HeapTuple tup = ExecMaterializeSlot(slot); heap_insert(ri->ri_RelationDesc, tup, GetCurrentCommandId(true), 0, NULL); ExecInsertCQMatRelIndexTuples(ri, slot, estate); }
/* * ExecCQMatViewUpdate * * Update an existing row of a CV materialization table. */ bool ExecCQMatRelUpdate(ResultRelInfo *ri, TupleTableSlot *slot, EState *estate) { HeapTuple tup = ExecMaterializeSlot(slot); bool updated = matrel_heap_update(ri->ri_RelationDesc, &tup->t_self, tup); if (!HeapTupleIsHeapOnly(tup)) ExecInsertCQMatRelIndexTuples(ri, slot, estate); return updated; }