Received: from odin2.bull.net (odin2.bull.net [192.90.70.84]) by postgresql.org (8.11.3/8.11.4) with ESMTP id g1CFkXE73560 for ; Tue, 12 Feb 2002 10:46:53 -0500 (EST) (envelope-from Jean-Max.Reymond@bull.net) Received: from pallas.frso.bull.fr (pallas.frso.bull.fr [129.181.16.48]) by odin2.bull.net (8.9.3/8.9.3) with ESMTP id QAA110456 for ; Tue, 12 Feb 2002 16:48:04 +0100 Received: from osiris.frml.bull.fr (osiris.frml.bull.fr [129.184.161.1]) by pallas.frso.bull.fr (8.9.2/8.9.2) with ESMTP id QAA38392 for ; Tue, 12 Feb 2002 16:46:24 +0100 Received: from bull.net (pc110.frml.bull.fr [129.184.161.3]) by osiris.frml.bull.fr (AIX4.3/8.9.3/8.7) with ESMTP id QAA43408 for ; Tue, 12 Feb 2002 16:46:57 +0100 Message-ID: <3C6938B3.3060208@bull.net> Date: Tue, 12 Feb 2002 16:45:55 +0100 From: Jean-Max Reymond Organization: BULL S.A User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.8) Gecko/20020204 X-Accept-Language: fr-fr, en-us MIME-Version: 1.0 To: pgsql-sql@postgresql.org Subject: SQL request to retrieve the type of columns Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Archive-Number: 200202/131 X-Sequence-Number: 6559 I am looking for a SQL request (must be executed in a ECPG program) to retrieve the type of each column in a Postgres table. For example, \d wapi Table "wapi" Attribute | Type | Modifier ------------+-----------------------+---------- wapinom | character(8) | wapicall | character varying(12) | wapitrans | character varying(4) | wapistruct | character varying(50) | It will be great to have the same result with a "select request". regards, -- Jean-Max Reymond ============================================================================ Email : Jean-Max.Reymond@bull.net Address: BULL SLDV (Saint Laurent du Var) ============================================================================