From jkanter@virginia.edu Thu Apr 21 18:38:20 2005 X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 945D55378D for ; Thu, 21 Apr 2005 15:38:20 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 60951-10 for ; Thu, 21 Apr 2005 18:38:17 +0000 (GMT) Received: from fork12.mail.virginia.edu (fork12.mail.Virginia.EDU [128.143.2.182]) by svr1.postgresql.org (Postfix) with ESMTP id 9CD4D53768 for ; Thu, 21 Apr 2005 15:38:07 -0300 (ADT) Received: from localhost (localhost [127.0.0.1]) by fork12.mail.virginia.edu (Postfix) with ESMTP id 271051F53BC for ; Thu, 21 Apr 2005 14:37:54 -0400 (EDT) Received: from fork12.mail.virginia.edu ([127.0.0.1]) by localhost (fork12.mail.virginia.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 27937-02 for ; Thu, 21 Apr 2005 14:37:53 -0400 (EDT) Received: from [137.54.133.131] (d-137-133-131.bootp.Virginia.EDU [137.54.133.131]) by fork12.mail.virginia.edu (Postfix) with ESMTP id E208E1F53B9 for ; Thu, 21 Apr 2005 14:37:53 -0400 (EDT) Message-ID: <4267F301.7050205@virginia.edu> Date: Thu, 21 Apr 2005 14:37:53 -0400 From: Jodi Kanter User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.2) Gecko/20040804 Netscape/7.2 (ax) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Postgres Admin List Subject: field names Content-Type: multipart/alternative; boundary="------------090801060601050200000201" X-UVA-Virus-Scanned: by amavisd-new at fork12.mail.virginia.edu X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.095 tagged_above=0 required=5 tests=AWL, HTML_MESSAGE, HTML_TITLE_EMPTY X-Spam-Level: X-Archive-Number: 200504/329 X-Sequence-Number: 17342 This is a multi-part message in MIME format. --------------090801060601050200000201 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit I'd like to check field names for various tables in our code. Is there a system table that lists the field names of each table? ...some way to query this information to run an error check? Thanks Jodi Kanter -- _______________________________ Jodi L Kanter BioInformatics Database Administrator University of Virginia (434) 924-2846 jkanter@virginia.edu --------------090801060601050200000201 Content-Type: text/html; charset=us-ascii Content-Transfer-Encoding: 7bit I'd like to check field names for various tables in our code. Is there a system table that lists the field names of each table? ...some way to query this information to run an error check?
Thanks
Jodi Kanter
--
_______________________________

_______________________________
Jodi L Kanter
BioInformatics Database Administrator
University of Virginia
(434) 924-2846
jkanter@virginia.edu

 

--------------090801060601050200000201-- From alvherre@dcc.uchile.cl Sat Apr 23 04:24:07 2005 X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 5789253516 for ; Sat, 23 Apr 2005 01:24:07 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 00225-05 for ; Sat, 23 Apr 2005 04:24:04 +0000 (GMT) Received: from sunsite.dcc.uchile.cl (sunsite.dcc.uchile.cl [192.80.24.2]) by svr1.postgresql.org (Postfix) with ESMTP id B4F1253513 for ; Sat, 23 Apr 2005 01:24:02 -0300 (ADT) Received: from anakena.dcc.uchile.cl (anakena [192.80.24.6]) by sunsite.dcc.uchile.cl (8.12.11/8.12.11) with ESMTP id j3N4O1tf024615; Sat, 23 Apr 2005 00:24:01 -0400 (CLT) Received: by anakena.dcc.uchile.cl (Postfix, from userid 4151) id 377B252FCC; Sat, 23 Apr 2005 00:24:01 -0400 (CLT) Date: Sat, 23 Apr 2005 00:24:01 -0400 From: Alvaro Herrera To: Jodi Kanter Cc: Postgres Admin List Subject: Re: field names Message-ID: <20050423042401.GA2260@dcc.uchile.cl> References: <4267F301.7050205@virginia.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <4267F301.7050205@virginia.edu> User-Agent: Mutt/1.5.8i X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.341 tagged_above=0 required=5 tests=AWL, DNS_FROM_RFC_ABUSE X-Spam-Level: X-Archive-Number: 200504/332 X-Sequence-Number: 17345 On Thu, Apr 21, 2005 at 02:37:53PM -0400, Jodi Kanter wrote: > I'd like to check field names for various tables in our code. Is there a > system table that lists the field names of each table? ...some way to > query this information to run an error check? Yes, pg_attribute. Or you could check the information_schema. See the docs on "system catalogs" in the Internals chapter. -- Alvaro Herrera () "Escucha y olvidarás; ve y recordarás; haz y entenderás" (Confucio) From mike@fuhr.org Sat Apr 23 04:30:59 2005 X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id D2FB5534F2 for ; Sat, 23 Apr 2005 01:30:59 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 02098-10 for ; Sat, 23 Apr 2005 04:30:46 +0000 (GMT) Received: from tigger.fuhr.org (tigger.fuhr.org [63.214.45.158]) by svr1.postgresql.org (Postfix) with ESMTP id C976C53727 for ; Sat, 23 Apr 2005 01:30:36 -0300 (ADT) Received: from winnie.fuhr.org (winnie.fuhr.org [10.1.0.1]) by tigger.fuhr.org (8.13.3/8.13.3) with ESMTP id j3N4UXfI035900 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 22 Apr 2005 22:30:35 -0600 (MDT) (envelope-from mfuhr@winnie.fuhr.org) Received: from winnie.fuhr.org (localhost [127.0.0.1]) by winnie.fuhr.org (8.13.3/8.13.3) with ESMTP id j3N4UX6s096258; Fri, 22 Apr 2005 22:30:33 -0600 (MDT) (envelope-from mfuhr@winnie.fuhr.org) Received: (from mfuhr@localhost) by winnie.fuhr.org (8.13.3/8.13.3/Submit) id j3N4UWC0096257; Fri, 22 Apr 2005 22:30:32 -0600 (MDT) (envelope-from mfuhr) Date: Fri, 22 Apr 2005 22:30:32 -0600 From: Michael Fuhr To: Jodi Kanter Cc: Postgres Admin List Subject: Re: field names Message-ID: <20050423043032.GA96231@winnie.fuhr.org> References: <4267F301.7050205@virginia.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4267F301.7050205@virginia.edu> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.004 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200504/334 X-Sequence-Number: 17347 On Thu, Apr 21, 2005 at 02:37:53PM -0400, Jodi Kanter wrote: > > I'd like to check field names for various tables in our code. Is there a > system table that lists the field names of each table? ...some way to > query this information to run an error check? See the "System Catalogs" and "The Information Schema" chapters in the documentation (the latter in 7.4 and later). -- Michael Fuhr http://www.fuhr.org/~mfuhr/