dbTalk Databases Forums  

sql query to get field types

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


Discuss sql query to get field types in the comp.databases.postgresql.general forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Alexander Cohen
 
Posts: n/a

Default sql query to get field types - 03-01-2004 , 04:54 PM






What sql query can i use to get all relative data to the types of
fields that a table contains?


--
Alexander Cohen
http://www.toomuchspace.com
(819) 348-9237
(819) 432-3443


---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster


Reply With Quote
  #2  
Old   
scott.marlowe
 
Posts: n/a

Default Re: sql query to get field types - 03-01-2004 , 04:57 PM






On Mon, 1 Mar 2004, Alexander Cohen wrote:

Quote:
What sql query can i use to get all relative data to the types of
fields that a table contains?
select column_name,data_type from information_schema.columns where
table_name='test';

works in 7.4


---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org



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.