Re: CONSTRAINT syntax in ALTER TABLE

Поиск
Список
Период
Сортировка
От Jim Nasby
Тема Re: CONSTRAINT syntax in ALTER TABLE
Дата
Msg-id D1D2D51E3BE3FC4E98598248901F759402C8907D@ausmail2k4.aus.pervasive.com
обсуждение исходный текст
Ответ на CONSTRAINT syntax in ALTER TABLE  ("Jim C. Nasby" <jnasby@pervasive.com>)
Список pgsql-docs
> From: Bruce Momjian [mailto:pgman@candle.pha.pa.us]
> > is (I assume) it would do nothing to help \h ALTER TABLE in
> psql. Maybe
> > a good compromise would be to include the table_constraint
> section of
> > the CREATE TABLE syntax in the ALTER TABLE syntax.
>
> If they created the table, they have already seen the
> constraint syntax.
> I see no reason to repeat it.

The reason I'd repeat it is because when you're going to modify
existing constraints, you'll be using ALTER TABLE. Sure, if the
user memorized the constraint syntax when they created the table,
they won't need extra help. Personally, I usually make use of
column-level constraints when writing DDL, so any time I need to
use table-level syntax I often have to look something up. That's
why I'd like to see the info in \h.

If you look at our docs from a newbie standpoint, they're not very
easy to use, because it's difficult to find stuff unless you know
where to look. If you're looking in the SQL Syntax section, ALTER
TABLE is the obvious choice if you need to change something about
the table, but it's a PITA to have to refer to other documentation
to find the full syntax for the command.
--
Jim C. Nasby, Sr. Engineering Consultant      jnasby@pervasive.com
Pervasive Software      http://pervasive.com    work: 512-231-6117
vcard: http://jim.nasby.net/pervasive.vcf       cell: 512-569-9461

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: mark wath catalogs are shared - was:(Re: [NOVICE] which database to login to to create global users?)
Следующее
От: "Jim C. Nasby"
Дата:
Сообщение: Re: [PATCHES] Summary table trigger example race condition