aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/table/tableamapi.c
diff options
context:
space:
mode:
authorAlexander Korotkov <akorotkov@postgresql.org>2024-04-02 11:26:59 +0300
committerAlexander Korotkov <akorotkov@postgresql.org>2024-04-02 11:29:00 +0300
commit867cc7b6ddb9d998103688a56048fe9a1ddd972a (patch)
tree401d95630a475b33df8af26b74a0cc6c819106bf /src/backend/access/table/tableamapi.c
parent667e65aac354975c6f8090c6146fceb8d7b762d6 (diff)
downloadpostgresql-867cc7b6ddb9d998103688a56048fe9a1ddd972a.tar.gz
postgresql-867cc7b6ddb9d998103688a56048fe9a1ddd972a.zip
Revert "Custom reloptions for table AM"
This reverts commit c95c25f9af4bc77f2f66a587735c50da08c12b37 due to multiple design issues spotted after commit. Reported-by: Jeff Davis Discussion: https://postgr.es/m/11550b536211d5748bb2865ed6cb3502ff073bf7.camel%40j-davis.com
Diffstat (limited to 'src/backend/access/table/tableamapi.c')
-rw-r--r--src/backend/access/table/tableamapi.c25
1 files changed, 0 insertions, 25 deletions
diff --git a/src/backend/access/table/tableamapi.c b/src/backend/access/table/tableamapi.c
index d9e23ef3175..55b8caeadf2 100644
--- a/src/backend/access/table/tableamapi.c
+++ b/src/backend/access/table/tableamapi.c
@@ -13,11 +13,9 @@
#include "access/tableam.h"
#include "access/xact.h"
-#include "catalog/pg_am.h"
#include "commands/defrem.h"
#include "miscadmin.h"
#include "utils/guc_hooks.h"
-#include "utils/syscache.h"
/*
@@ -100,29 +98,6 @@ GetTableAmRoutine(Oid amhandler)
return routine;
}
-/*
- * GetTableAmRoutineByAmOid
- * Given the table access method oid get its TableAmRoutine struct, which
- * will be palloc'd in the caller's memory context.
- */
-const TableAmRoutine *
-GetTableAmRoutineByAmOid(Oid amoid)
-{
- HeapTuple ht_am;
- Form_pg_am amrec;
- const TableAmRoutine *tableam = NULL;
-
- ht_am = SearchSysCache1(AMOID, ObjectIdGetDatum(amoid));
- if (!HeapTupleIsValid(ht_am))
- elog(ERROR, "cache lookup failed for access method %u",
- amoid);
- amrec = (Form_pg_am) GETSTRUCT(ht_am);
-
- tableam = GetTableAmRoutine(amrec->amhandler);
- ReleaseSysCache(ht_am);
- return tableam;
-}
-
/* check_hook: validate new default_table_access_method */
bool
check_default_table_access_method(char **newval, void **extra, GucSource source)