dbTalk Databases Forums  

Oid to text...

comp.databases.postgresql.general comp.databases.postgresql.general


Discuss Oid to text... in the comp.databases.postgresql.general forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Katsaros Kwn/nos
 
Posts: n/a

Default Oid to text... - 11-22-2004 , 06:25 AM






Hi,

Given the Oid restype of a Resdom "object", is there any system table I
could query in order to retrieve the text representation of this type?

If for example a Resdom restype is 23 how can I get the string "integer"
or something like that? Are these mappings stored anyware?

Thanks in advance,
Ntinos Katsaros

PS: I searched the archives but my queries did not give anything...


---------------------------(end of broadcast)---------------------------
TIP 9: the planner will ignore your desire to choose an index scan if your
joining column's datatypes do not match


Reply With Quote
  #2  
Old   
Ian Barwick
 
Posts: n/a

Default Re: Oid to text... - 11-22-2004 , 06:51 AM






On 22 Nov 2004 14:25:26 +0200, Katsaros Kwn/nos <ntinos (AT) aueb (DOT) gr> wrote:
Quote:
Hi,

Given the Oid restype of a Resdom "object", is there any system table I
could query in order to retrieve the text representation of this type?

If for example a Resdom restype is 23 how can I get the string "integer"
or something like that? Are these mappings stored anyware?
pg_catalog.pg_type ?

Ian Barwick

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to majordomo (AT) postgresql (DOT) org)



Reply With Quote
  #3  
Old   
Tom Lane
 
Posts: n/a

Default Re: Oid to text... - 11-22-2004 , 10:00 AM



"Katsaros Kwn/nos" <ntinos (AT) aueb (DOT) gr> writes:
Quote:
Given the Oid restype of a Resdom "object", is there any system table I
could query in order to retrieve the text representation of this type?
If you're talking about C code inside the backend, format_type_be() is
the usual subroutine.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faqs/FAQ.html



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.