Re: BUG #4689: Expanding the length of a VARCHAR column should not induce a table rewrite

Поиск
Список
Период
Сортировка
Искать
От
Peter Eisentraut
Тема
Re: BUG #4689: Expanding the length of a VARCHAR column should not induce a table rewrite
Дата
Msg-id
49AE5CE7.8010508@gmx.net
Ответ на
Список
Дерево обсуждения
BUG #4689: Expanding the length of a VARCHAR column should not induce a table rewrite "" <xuan--2009.03--submitbug--support--postgresql.org@baldauf.org>
Re: BUG #4689: Expanding the length of a VARCHAR column should not induce a table rewrite Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>
Re: BUG #4689: Expanding the length of a VARCHAR column should not induce a table rewrite Peter Eisentraut <peter_e@gmx.net>
Re: BUG #4689: Expanding the length of a VARCHAR column should not induce a table rewrite Guillaume Smet <guillaume.smet@gmail.com>
Re: [HACKERS] Re: BUG #4689: Expanding the length of a VARCHAR column should not induce a table rewrite Jaime Casanova <jcasanov@systemguards.com.ec>
Heikki Linnakangas wrote:
> xuan--2009.03--submitbug--support--postgresql.org@baldauf.org wrote:
>> When executing
>> "ALTER TABLE sometable ALTER COLUMN somecolumn TYPE VARCHAR(7)", the 
>> whole
>> table is re-written, and this rewrite takes many hours. During these 
>> hours,
>> all writers on this table stall, making the database effectively
>> unavailable.
>>
>> However, in almost all cases, there is no need for such relaxing of 
>> limits
>> to require a table rewrite.
> 
> While this isn't a bug, it's a reasonable feature request. I've added 
> this to the TODO page: http://wiki.postgresql.org/wiki/Todo#ALTER
> 
> Patches are welcome.

The question is how you want to implement this in a data type 
independent fashion.  You can't assume that increasing the typmod is a 
noop for all data types.
В списке pgsql-bugs по дате отправления
От: vikas
Дата:
От: Peter Eisentraut
Дата:
FAQ