Hi,
stanciutheone(at)gmail(dot)com wrote:
> is just a varchar field that i want to make it bigge ,right now the
> alter table is working for over 6 hours
You can try to update the pg_attribute table directly. Just first do some
select statements to ensure you only update what you really want to.
Also, make a backup before you do it.
update pg_attribute set attlen = 4 + <newlength>
where attname = 'yourcolumnname'
That will take only a couple of milliseconds to do.
I used this before in scenarios where the column to be changed was
referenced in many queries making it almost impossible to do a drop and
recreating of the queries without any side effects.
HTH,
Johan Nel
Pretoria, South Africa.