Frank Kurzawa <fkurzawa(at)topazsoftware(dot)com> writes:
> How can I find out what object corresponds to a given OID in the
> relation column in the pg_locks table?
Join to pg_class.oid:
select relname from pg_locks, pg_class where relation = pg_class.oid;
or cast it to regclass:
select relation::regclass from pg_locks;
regards, tom lane