Re: create table like . . . constraint names

Поиск
Список
Период
Сортировка
От Vincent Veyron
Тема Re: create table like . . . constraint names
Дата
Msg-id 1345954283.2860.15.camel@asus-1001PX.home
обсуждение исходный текст
Ответ на create table like . . . constraint names  ("Sahagian, David" <david.sahagian@emc.com>)
Список pgsql-general
Le vendredi 24 août 2012 à 09:27 -0400, Sahagian, David a écrit :
> Is there any way for me to control the name of the (unique or primary)
> constraints that get created when doing a “create table like
> parent-table” statement ?

I suppose that you use 'INCLUDING CONSTRAINTS' in your LIKE clause,
since constraints are copied?

You can drop the constraint and re-create it with the name you want :

http://www.postgresql.org/docs/9.1/static/sql-altertable.html


--
Vincent Veyron
http://vincentveyron.com/
Gestion informatique des sinistres d'assurances et des dossiers contentieux pour le service juridique




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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Permission denied for relation pg_database , one role has problem
Следующее
От: Michael Clark
Дата:
Сообщение: Re: postmaster.pid file auto-clean up?