Re: Get the table creation DDL

Поиск
Список
Период
Сортировка
От Ray O'Donnell
Тема Re: Get the table creation DDL
Дата
Msg-id 88e4ccd9-0fea-f18f-7541-33c7838e1989@rodonnell.ie
обсуждение исходный текст
Ответ на Re: Get the table creation DDL  (Igor Korot <ikorot01@gmail.com>)
Ответы Re: Get the table creation DDL  (Igor Korot <ikorot01@gmail.com>)
Список pgsql-general
On 10/07/2022 17:47, Igor Korot wrote:
> Hi, Michael,
> 
> On Sun, Jul 10, 2022 at 11:13 AM Michael Nolan <htfoot@gmail.com> wrote:
>>
>>
>>
>> On Sun, Jul 10, 2022 at 10:28 AM Igor Korot <ikorot01@gmail.com> 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@rodonnell.ie



В списке pgsql-general по дате отправления:

Предыдущее
От: Igor Korot
Дата:
Сообщение: Re: Get the table creation DDL
Следующее
От: Michael Nolan
Дата:
Сообщение: Re: Get the table creation DDL