summaryrefslogtreecommitdiff
path: root/src/backend/commands/comment.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/commands/comment.c')
-rw-r--r--src/backend/commands/comment.c16
1 files changed, 4 insertions, 12 deletions
diff --git a/src/backend/commands/comment.c b/src/backend/commands/comment.c
index ada0b0356ad..8a437de8154 100644
--- a/src/backend/commands/comment.c
+++ b/src/backend/commands/comment.c
@@ -199,7 +199,7 @@ CreateComments(Oid oid, Oid classoid, int32 subid, char *comment)
{
newtuple = heap_modify_tuple(oldtuple, RelationGetDescr(description), values,
nulls, replaces);
- simple_heap_update(description, &oldtuple->t_self, newtuple);
+ CatalogTupleUpdate(description, &oldtuple->t_self, newtuple);
}
break; /* Assume there can be only one match */
@@ -213,15 +213,11 @@ CreateComments(Oid oid, Oid classoid, int32 subid, char *comment)
{
newtuple = heap_form_tuple(RelationGetDescr(description),
values, nulls);
- simple_heap_insert(description, newtuple);
+ CatalogTupleInsert(description, newtuple);
}
- /* Update indexes, if necessary */
if (newtuple != NULL)
- {
- CatalogUpdateIndexes(description, newtuple);
heap_freetuple(newtuple);
- }
/* Done */
@@ -293,7 +289,7 @@ CreateSharedComments(Oid oid, Oid classoid, char *comment)
{
newtuple = heap_modify_tuple(oldtuple, RelationGetDescr(shdescription),
values, nulls, replaces);
- simple_heap_update(shdescription, &oldtuple->t_self, newtuple);
+ CatalogTupleUpdate(shdescription, &oldtuple->t_self, newtuple);
}
break; /* Assume there can be only one match */
@@ -307,15 +303,11 @@ CreateSharedComments(Oid oid, Oid classoid, char *comment)
{
newtuple = heap_form_tuple(RelationGetDescr(shdescription),
values, nulls);
- simple_heap_insert(shdescription, newtuple);
+ CatalogTupleInsert(shdescription, newtuple);
}
- /* Update indexes, if necessary */
if (newtuple != NULL)
- {
- CatalogUpdateIndexes(shdescription, newtuple);
heap_freetuple(newtuple);
- }
/* Done */