Re: How to get RelationName ?? - Mailing list pgsql-hackers

From Jonathan Gardner
Subject Re: How to get RelationName ??
Date
Msg-id 200403101527.26418.jgardner@jonathangardner.net
Whole thread Raw
In response to How to get RelationName ??  ("Ramanujam H S Iyengar" <hals_ramu@hotmail.com>)
List pgsql-hackers
On Wednesday 10 March 2004 09:58 am, Ramanujam H S Iyengar wrote:
> Hello,
>
> How can i get the name of a relation from its Oid ?? I have seen some
> functions in utils/cache/relcache.h like RelationIdGetRelation - which
> gives Relation Node from Oid RelationSysNameGetRelation - which gives
> Relation node for only the System names.
>
> Can anyone please tell me how to get Relation node from relation name ???
>

Won't you have to go get the data from the database for this? I mean 
actually execute the query:

select relname from pg_class where oid = 1234;

-- 
Jonathan Gardner
jgardner@jonathangardner.net


pgsql-hackers by date:

Previous
From: "Thomas Swan"
Date:
Subject: Re: [GENERAL] Shouldn't B'1' = 1::bit be true?
Next
From: Bruce Momjian
Date:
Subject: Re: selective statement logging