Re: Getting table name/tuple from OID
| От | Martijn van Oosterhout |
|---|---|
| Тема | Re: Getting table name/tuple from OID |
| Дата | |
| Msg-id | 20051111140405.GG13177@svana.org обсуждение исходный текст |
| Ответ на | Re: Getting table name/tuple from OID (huaxin zhang <uwcssa@gmail.com>) |
| Список | pgsql-hackers |
On Fri, Nov 11, 2005 at 08:37:07AM -0500, huaxin zhang wrote: > Hi all, > > I am interested in the answer as well -- how to get a table name (or > an operator name) from an OID. the parser must know how to do this, > but the segment of code is hard to locate. For the purposes of error messages, RelationGetRelationName() does what you want. Otherwise maybe RelationIdGetRelation(Oid relationId). Check out utils/cache/relcache.c for a variety of functions to extract basic data like this. Hope this helps, -- Martijn van Oosterhout <kleptog@svana.org> http://svana.org/kleptog/ > Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a > tool for doing 5% of the work and then sitting around waiting for someone > else to do the other 95% so you can sue them.
В списке pgsql-hackers по дате отправления: