On 2022-Apr-12, Amit Kapila wrote:
> I mean that it fetches the tuple from the RELOID cache and then
> performs relkind and other checks similar to what we are doing. I
> think it could also have used get_rel_relkind() but probably not done
> because it doesn't have a lock on the relation.
Ah, but that one uses a lot more fields from the pg_class tuple in the
non-error path. We only need relkind, up until we know the error is to
be thrown.
--
Álvaro Herrera PostgreSQL Developer — https://www.EnterpriseDB.com/