Re: Reordering columns in a table

Поиск
Список
Период
Сортировка
От Berend Tober
Тема Re: Reordering columns in a table
Дата
Msg-id 43BEC8BD.2020908@seaworthysys.com
обсуждение исходный текст
Ответ на Re: Reordering columns in a table  (Andreas Kretschmer <akretschmer@spamfence.net>)
Список pgsql-general
Andreas Kretschmer wrote:

>John McCawley <nospam@hardgeus.com> schrieb:
>
>
>>However, in the real world, ...
>>
>>
>
>...And i think, other systems do this:
>
>- begin
>- create a new temp. table with the new order
>- insert all values from the old table in the new temp. table
>- drop the old table
>- rename the temp. table to the old table name
>- commit
>
>You can do the same, no problem.
>
>
>

Except for the details regarding dependent views and foreign key
references... (as someone mentioned mentioned earlier!). And you
probably wouldn't want to do that on an in-production system, I would
think, although the transaction block prehaps provides appropriate
protection.

Regards,
Berend Tober



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

Предыдущее
От: John McCawley
Дата:
Сообщение: Re: Reordering columns in a table
Следующее
От: Wes
Дата:
Сообщение: ./configure --with-openssl=path fails