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)