1
0
mirror of https://github.com/postgres/postgres.git synced 2025-09-11 00:12:06 +03:00

Use Snapshot in heap access methods.

This commit is contained in:
Vadim B. Mikheev
1998-07-27 19:38:40 +00:00
parent f7f989c990
commit be8300b18f
54 changed files with 352 additions and 339 deletions

View File

@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/optimizer/path/indxpath.c,v 1.17 1998/07/18 04:22:31 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/optimizer/path/indxpath.c,v 1.18 1998/07/27 19:37:58 vadim Exp $
*
*-------------------------------------------------------------------------
*/
@@ -979,7 +979,7 @@ clause_pred_clause_test(Expr *predicate, Node *clause)
* will be used to find the associated strategy numbers for the test.
* --Nels, Jan '93
*/
scan = heap_beginscan(relation, false, false, 2, entry);
scan = heap_beginscan(relation, false, SnapshotNow, 2, entry);
tuple = heap_getnext(scan, false, (Buffer *) NULL);
if (!HeapTupleIsValid(tuple))
{
@@ -1010,7 +1010,7 @@ clause_pred_clause_test(Expr *predicate, Node *clause)
F_OIDEQ,
ObjectIdGetDatum(clause_op));
scan = heap_beginscan(relation, false, false, 3, entry);
scan = heap_beginscan(relation, false, SnapshotNow, 3, entry);
tuple = heap_getnext(scan, false, (Buffer *) NULL);
if (!HeapTupleIsValid(tuple))
{
@@ -1042,7 +1042,7 @@ clause_pred_clause_test(Expr *predicate, Node *clause)
F_INT2EQ,
Int16GetDatum(test_strategy));
scan = heap_beginscan(relation, false, false, 3, entry);
scan = heap_beginscan(relation, false, SnapshotNow, 3, entry);
tuple = heap_getnext(scan, false, (Buffer *) NULL);
if (!HeapTupleIsValid(tuple))
{

View File

@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/optimizer/util/plancat.c,v 1.17 1998/06/15 19:28:49 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/optimizer/util/plancat.c,v 1.18 1998/07/27 19:38:00 vadim Exp $
*
*-------------------------------------------------------------------------
*/
@@ -148,7 +148,7 @@ index_info(Query *root, bool first, int relid, IdxInfoRetval *info)
ObjectIdGetDatum(indrelid));
relation = heap_openr(IndexRelationName);
scan = heap_beginscan(relation, 0, false,
scan = heap_beginscan(relation, 0, SnapshotNow,
1, &indexKey);
}
if (!HeapScanIsValid(scan))
@@ -413,7 +413,7 @@ find_inheritance_children(Oid inhparent)
key[0].sk_argument = ObjectIdGetDatum((Oid) inhparent);
relation = heap_openr(InheritsRelationName);
scan = heap_beginscan(relation, 0, false, 1, key);
scan = heap_beginscan(relation, 0, SnapshotNow, 1, key);
while (HeapTupleIsValid(inheritsTuple =
heap_getnext(scan, 0,
(Buffer *) NULL)))
@@ -449,7 +449,7 @@ VersionGetParents(Oid verrelid)
key[0].sk_nargs = key[0].sk_func.fn_nargs;
relation = heap_openr(VersionRelationName);
key[0].sk_argument = ObjectIdGetDatum(verrelid);
scan = heap_beginscan(relation, 0, false, 1, key);
scan = heap_beginscan(relation, 0, SnapshotNow, 1, key);
for (;;)
{
versionTuple = heap_getnext(scan, 0,