mirror of
https://github.com/postgres/postgres.git
synced 2025-11-07 19:06:32 +03:00
Fix temp relation handling for indexes, cleanup
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/catalog/index.c,v 1.127 2000/10/05 19:48:21 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/catalog/index.c,v 1.128 2000/10/11 21:28:18 momjian Exp $
|
||||
*
|
||||
*
|
||||
* INTERFACE ROUTINES
|
||||
@@ -1145,7 +1145,7 @@ index_drop(Oid indexId)
|
||||
RelationForgetRelation(indexId);
|
||||
|
||||
/* does something only if it is a temp index */
|
||||
remove_temp_relation(indexId);
|
||||
remove_temp_rel_by_relid(indexId);
|
||||
}
|
||||
|
||||
/* ----------------------------------------------------------------
|
||||
@@ -1374,7 +1374,7 @@ IndexesAreActive(Oid relid, bool confirmCommitted)
|
||||
if (!LockClassinfoForUpdate(relid, &tuple, &buffer, confirmCommitted))
|
||||
elog(ERROR, "IndexesAreActive couldn't lock %u", relid);
|
||||
if (((Form_pg_class) GETSTRUCT(&tuple))->relkind != RELKIND_RELATION &&
|
||||
((Form_pg_class) GETSTRUCT(&tuple))->relkind != RELKIND_TOASTVALUE)
|
||||
((Form_pg_class) GETSTRUCT(&tuple))->relkind != RELKIND_TOASTVALUE)
|
||||
elog(ERROR, "relation %u isn't an indexable relation", relid);
|
||||
isactive = ((Form_pg_class) GETSTRUCT(&tuple))->relhasindex;
|
||||
ReleaseBuffer(buffer);
|
||||
|
||||
Reference in New Issue
Block a user