From 675457d6abad99f4f7f4501bdf2c1bf064c912a4 Mon Sep 17 00:00:00 2001 From: "Vadim B. Mikheev" Date: Fri, 10 Jan 1997 09:46:33 +0000 Subject: [PATCH] index_insert has now HeapRelation as last param (for unique index implementation). --- src/backend/access/gist/gist.c | 2 +- src/backend/access/hash/hash.c | 4 ++-- src/backend/access/index/indexam.c | 6 +++--- src/backend/access/nbtree/nbtree.c | 8 ++++---- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/backend/access/gist/gist.c b/src/backend/access/gist/gist.c index 5188c8bf90..cc14a2e448 100644 --- a/src/backend/access/gist/gist.c +++ b/src/backend/access/gist/gist.c @@ -292,7 +292,7 @@ gistbuild(Relation heap, * It doesn't do any work; just locks the relation and passes the buck. */ InsertIndexResult -gistinsert(Relation r, Datum *datum, char *nulls, ItemPointer ht_ctid, bool is_update) +gistinsert(Relation r, Datum *datum, char *nulls, ItemPointer ht_ctid, Relation heapRel) { InsertIndexResult res; IndexTuple itup; diff --git a/src/backend/access/hash/hash.c b/src/backend/access/hash/hash.c index 973902c85c..89f81fc56a 100644 --- a/src/backend/access/hash/hash.c +++ b/src/backend/access/hash/hash.c @@ -7,7 +7,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/access/hash/hash.c,v 1.11 1996/11/13 20:46:48 scrappy Exp $ + * $Header: /cvsroot/pgsql/src/backend/access/hash/hash.c,v 1.12 1997/01/10 09:46:13 vadim Exp $ * * NOTES * This file contains only the public interface routines. @@ -257,7 +257,7 @@ hashbuild(Relation heap, * to the caller. */ InsertIndexResult -hashinsert(Relation rel, Datum *datum, char *nulls, ItemPointer ht_ctid, bool is_update) +hashinsert(Relation rel, Datum *datum, char *nulls, ItemPointer ht_ctid, Relation heapRel) { HashItem hitem; IndexTuple itup; diff --git a/src/backend/access/index/indexam.c b/src/backend/access/index/indexam.c index 93539cc82b..245ff4861a 100644 --- a/src/backend/access/index/indexam.c +++ b/src/backend/access/index/indexam.c @@ -7,7 +7,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/access/index/indexam.c,v 1.9 1996/12/26 17:44:46 momjian Exp $ + * $Header: /cvsroot/pgsql/src/backend/access/index/indexam.c,v 1.10 1997/01/10 09:46:25 vadim Exp $ * * INTERFACE ROUTINES * index_open - open an index relation by relationId @@ -165,7 +165,7 @@ index_insert(Relation relation, Datum *datum, char *nulls, ItemPointer heap_t_ctid, - bool is_update) + Relation heapRel) { RegProcedure procedure; InsertIndexResult specificResult; @@ -178,7 +178,7 @@ index_insert(Relation relation, * ---------------- */ specificResult = (InsertIndexResult) - fmgr(procedure, relation, datum, nulls, heap_t_ctid, is_update, NULL); + fmgr(procedure, relation, datum, nulls, heap_t_ctid, heapRel, NULL); /* ---------------- * the insert proc is supposed to return a "specific result" and diff --git a/src/backend/access/nbtree/nbtree.c b/src/backend/access/nbtree/nbtree.c index 203282b687..2ecce30863 100644 --- a/src/backend/access/nbtree/nbtree.c +++ b/src/backend/access/nbtree/nbtree.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtree.c,v 1.11 1996/11/15 18:36:59 momjian Exp $ + * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtree.c,v 1.12 1997/01/10 09:46:33 vadim Exp $ * * NOTES * This file contains only the public interface routines. @@ -222,7 +222,7 @@ btbuild(Relation heap, if (FastBuild) { _bt_spool(index, btitem, spool); } else { - res = _bt_doinsert(index, btitem, isunique, false); + res = _bt_doinsert(index, btitem, isunique, heap); } pfree(btitem); @@ -292,7 +292,7 @@ btbuild(Relation heap, * return an InsertIndexResult to the caller. */ InsertIndexResult -btinsert(Relation rel, Datum *datum, char *nulls, ItemPointer ht_ctid, bool is_update) +btinsert(Relation rel, Datum *datum, char *nulls, ItemPointer ht_ctid, Relation heapRel) { BTItem btitem; IndexTuple itup; @@ -308,7 +308,7 @@ btinsert(Relation rel, Datum *datum, char *nulls, ItemPointer ht_ctid, bool is_u btitem = _bt_formitem(itup); res = _bt_doinsert(rel, btitem, - IndexIsUnique(RelationGetRelationId(rel)), is_update); + IndexIsUnique(RelationGetRelationId(rel)), heapRel); pfree(btitem); pfree(itup); -- 2.40.0