diff options
Diffstat (limited to 'src/include/utils/rel.h')
-rw-r--r-- | src/include/utils/rel.h | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/include/utils/rel.h b/src/include/utils/rel.h index 1d054653039..9d805ca23d2 100644 --- a/src/include/utils/rel.h +++ b/src/include/utils/rel.h @@ -124,6 +124,20 @@ typedef struct RelationData */ bytea *rd_options; /* parsed pg_class.reloptions */ + /* + * Oid of the handler for this relation. For an index this is a function + * returning IndexAmRoutine, for table like relations a function returning + * TableAmRoutine. This is stored separately from rd_indam, rd_tableam as + * its lookup requires syscache access, but during relcache bootstrap we + * need to be able to initialize rd_tableam without syscache lookups. + */ + Oid rd_amhandler; /* OID of index AM's handler function */ + + /* + * Table access method. + */ + const struct TableAmRoutine *rd_tableam; + /* These are non-NULL only for an index relation: */ Form_pg_index rd_index; /* pg_index tuple describing this index */ /* use "struct" here to avoid needing to include htup.h: */ @@ -144,7 +158,6 @@ typedef struct RelationData * rd_indexcxt. A relcache reset will include freeing that chunk and * setting rd_amcache = NULL. */ - Oid rd_amhandler; /* OID of index AM's handler function */ MemoryContext rd_indexcxt; /* private memory cxt for this stuff */ /* use "struct" here to avoid needing to include amapi.h: */ struct IndexAmRoutine *rd_indam; /* index AM's API struct */ |