Re: ALTER TABLE TODO items

Поиск
Список
Период
Сортировка
От Rod Taylor
Тема Re: ALTER TABLE TODO items
Дата
Msg-id 1083900068.22610.114.camel@jester
обсуждение исходный текст
Ответ на Re: ALTER TABLE TODO items  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: ALTER TABLE TODO items
Список pgsql-hackers
> > Also, should the syntax be SET TYPE, not just TYPE?
> 
> Shrug ... I dunno whether Rod had a precedent for that choice or not.

FireBird: ALTER COLUMN <column> TYPE <type>
DB2:    ALTER COLUMN <column> SET DATA TYPE <type>.
Oracle:    MODIFY <column> <type>
MSSQL:    ALTER COLUMN <column> <type> <constraints>
MySQL:    Both Oracle and MSSQL
Sap:    MODIFY <column> <type>

Spec:    Nothing (obvious) on changing column types

MODIFY is horrible. It seems to drop all constraints, defaults, etc that
are not specified in the second definition. It is essentially a
replacement of the column.

FireBird is the closest to our implementation. DB2 only allows changing
the length of a VARCHAR and even then it is restrictive in the amount
the length can change by.

I remember polling -hackers to see if there were objections at the time,
but the syntax is easy enough to change if you wish.



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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: psql 7.3.4 disagrees with NATURAL CROSS JOIN
Следующее
От: Tom Lane
Дата:
Сообщение: Re: ALTER TABLE TODO items