Re: conditional dropping of columns/constraints

Поиск
Список
Период
Сортировка
От Andrew Dunstan
Тема Re: conditional dropping of columns/constraints
Дата
Msg-id 4A005757.3000007@dunslane.net
обсуждение исходный текст
Ответ на Re: conditional dropping of columns/constraints  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers

Robert Haas wrote:
> On Tue, May 5, 2009 at 8:56 AM, Andrew Dunstan <andrew@dunslane.net> wrote:
>   
>> We have debated CREATE ... IF NOT EXISTS in the past, and there is no
>> consensus on what it should do, so we don't have it for any command. That is
>> quite a different case from what's being asked for, and the two should not
>> be conflated.
>>     
>
> I must be missing something, because the semantics of CREATE ... IF
> NOT EXISTS seem pretty well-defined to me, at least for any object
> that has a name.  Check whether that name is in use; if not, create
> the object per the specified definition.  
>   

And if it does exist but the definitions don't match? That's the issue 
on which there has not been consensus. You apparently thing the command 
should silently do nothing, but that's not what everyone thinks. (I have 
no very strong feelings on the subject - I'm just explaining the issue.)

cheers

andrew


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: conditional dropping of columns/constraints
Следующее
От: "Greg Sabino Mullane"
Дата:
Сообщение: Re: Prepared transactions vs novice DBAs, again