X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 8DC50DA361 for ; Sat, 5 Nov 2005 14:00:07 -0400 (AST) 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 11508-06 for ; Sat, 5 Nov 2005 18:00:05 +0000 (GMT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.177]) by svr1.postgresql.org (Postfix) with ESMTP id 42202DA298 for ; Sat, 5 Nov 2005 14:00:04 -0400 (AST) Received: from [194.25.154.138] (helo=webserv.wug.de) by mrelayeu.kundenserver.de (node=mrelayeu3) with ESMTP (Nemesis), id 0MKxQS-1EYSKg0Loo-0005kB; Sat, 05 Nov 2005 19:00:02 +0100 Received: from kretschmer by webserv.wug.de with local (Exim 3.36 #1) id 1EYSL4-0002r9-00 for pgsql-sql@postgresql.org; Sat, 05 Nov 2005 19:00:26 +0100 Date: Sat, 5 Nov 2005 19:00:26 +0100 From: "A. Kretschmer" To: pgsql-sql@postgresql.org Subject: Re: Extract table columns in tabular form Message-ID: <20051105180026.GA10871@webserv.wug-glas.de> Mail-Followup-To: "A. Kretschmer" , pgsql-sql@postgresql.org References: <1131209276.436ce23cba2d2@webmail.adontendev.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1131209276.436ce23cba2d2@webmail.adontendev.net> X-DEST: 208 X-MSMail-Priority: High X-Message-Flag: Really, I'm not out to destroy Microsoft. That will just be a completely unintentional side effect. (Linus Torvalds) X-OS: Linux - weil ich es mir Wert bin! X-Info: registrierter Linux-User 97922 http://counter.li.org User-Agent: mutt-ng 1.5.9i (Linux) X-Provags-ID: kundenserver.de abuse@kundenserver.de login:51ea9561fc3f6d9539a2acd743e4748c X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=1.429 required=5 tests=[AWL=0.035, MISSING_MIMEOLE=1.394] X-Spam-Score: 1.429 X-Spam-Level: * X-Archive-Number: 200511/61 X-Sequence-Number: 23312 am 05.11.2005, um 16:47:56 +0000 mailte frank church folgendes: > > How do you extract postgresql column names, types and comments in tabular form, > using an SQL command?. I know they are stored in one of the system tables, but > I don't know which. Start psql with -E and call \d* - commands to see both the hidden SQL and the description. Example: comment on table foo is 'this is a comment'; \dd foo [many lines of output the SQL and the comment] Use '\h?' to see all psql-commands. HTH, Andreas -- Andreas Kretschmer (Kontakt: siehe Header) Heynitz: 035242/47212, D1: 0160/7141639 GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net === Schollglas Unternehmensgruppe ===