Search Postgresql Archives

Re: Get the table creation DDL

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 10/07/2022 17:47, Igor Korot wrote:
Hi, Michael,

On Sun, Jul 10, 2022 at 11:13 AM Michael Nolan <htfoot@xxxxxxxxx> wrote:



On Sun, Jul 10, 2022 at 10:28 AM Igor Korot <ikorot01@xxxxxxxxx> wrote:

Hi,
Is there a query I can execute that will give me CREATE TABLE() command
used to create a table?

So there is no "query" per se?
Also how do I pass the table name?


If you connect to the database with psql including the -E option, then do

    \d <table name>

It will show you the SQL used to generate the output... this may help.

Ray.


--
Raymond O'Donnell // Galway // Ireland
ray@xxxxxxxxxxxx





[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux