From: A. Kretschmer <andreas.kretschmer@schollglas.com>
To: pgsql-sql@postgresql.org
Subject: Re: how do I get table DDL from psql (not from pg_dump)
Date: Wed, 27 Feb 2008 13:19:11 +0100
Message-ID: <20080227121911.GE21865@a-kretschmer.de> (raw)
In-Reply-To: <BE67D1149BBD5746984545ED91F702E0BD4AE3@hou-ex-02.adprod.bmc.com>
References: <BE67D1149BBD5746984545ED91F702E0BD4AE3@hou-ex-02.adprod.bmc.com>
am Wed, dem 27.02.2008, um 5:22:33 -0600 mailte Sofer, Yuval folgendes:
> Hi
>
>
>
> I need to extract table DDL (create script) from database connection (using
> sql, by retrieving system table info or by activating some pg function)
>
>
>
> Is this possible in postgres?
Why not using pg_dump?
You can specify with -n and -t an arbitrary table and with -s you get
only the DDL, not the data.
Andreas
--
Andreas Kretschmer
Kontakt: Heynitz: 035242/47150, D1: 0160/7141639 (mehr: -> Header)
GnuPG-ID: 0x3FFF606C, privat 0x7F4584DA http://wwwkeys.de.pgp.net
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: andreas.kretschmer@schollglas.com
Subject: Re: how do I get table DDL from psql (not from pg_dump)
In-Reply-To: <20080227121911.GE21865@a-kretschmer.de>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox