Changing Data Type on Production Database - Impact

Поиск
Список
Период
Сортировка
От Raj kumar
Тема Changing Data Type on Production Database - Impact
Дата
Msg-id CACxU--UnGQzyiLnOkGAoEZ16S0LJGFXUthirZFxO6mq=CqF4fQ@mail.gmail.com
обсуждение исходный текст
Список pgsql-admin

Hi,


I have a UseCase to modify the Data Types of some columns in a Table as specified below. 

How much time does it take approximately for modifying a 30GB table? Should I perform this only during Downtime or can I do it on a Production Database?


Data Type Changes,

test=> alter table speed1 alter column expireat type date USING expireat::date;

ALTER TABLE

 

test=> alter table speed1 alter column condition type jsonb[] USING condition::jsonb[];

ALTER TABLE

 

test=> alter table speed1 alter column last_login type timestamp with time zone USING last_login::timestamp with time zone;

ALTER TABLE


test=> alter table speed1 alter column remote_addr type inet USING remote_addr::inet;

ALTER TABLE


Thanks,

Raj Kumar Narendiran.

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

Предыдущее
От: Raj kumar
Дата:
Сообщение: Logical Replication - Initial Snapshot Only mode
Следующее
От: A G
Дата:
Сообщение: Re: Losing records in PostgreSQL 9.6