Re: Add a NOT NULL column with default only during add

Поиск
Список
Период
Сортировка
От Vik Fearing
Тема Re: Add a NOT NULL column with default only during add
Дата
Msg-id 51FB72FA.9010107@dalibo.com
обсуждение исходный текст
Ответ на Re: Add a NOT NULL column with default only during add  (BladeOfLight16 <bladeoflight16@gmail.com>)
Список pgsql-general
On 08/02/2013 10:03 AM, BladeOfLight16 wrote:
> So my question is effectively this: Is there an existing, equivalent,
> single DDL statement to the following hypothetical SQL?
>
> ALTER TABLE x
> ADD COLUMN data2 VARCHAR(10) NOT NULL USING 'foo';
>
> where "USING" here would indicate the same thing it does in an ALTER
> COLUMN data2 TYPE [data type] USING 'foo' command.
>
> I suspect the answer is "No, this feature does not exist right now,"
> and that's fine if so. I am just asking if my guess is correct or if
> I've missed the feature somewhere.

Your guess is unfortunately correct.

Vik


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

Предыдущее
От: Albe Laurenz
Дата:
Сообщение: Re: Recovery_target_time misinterpreted?
Следующее
От: Klaus Ita
Дата:
Сообщение: Re: Recovery_target_time misinterpreted?