Re: possible improvement for column resizing

From: Guillaume Lelarge <guillaume(at)lelarge(dot)info>
To: "Belbin, Peter" <Peter(dot)Belbin(at)PAETEC(dot)com>
Cc: "pgadmin-support(at)postgresql(dot)org" <pgadmin-support(at)postgresql(dot)org>
Subject: Re: possible improvement for column resizing
Date: 2011-09-24 00:06:06
Message-ID: 1316822767.2049.19.camel@localhost.localdomain
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-support

On Tue, 2011-09-20 at 09:13 -0500, Belbin, Peter wrote:
> Is there a reason why either pgAdmin or postgresql itself can not use the following method for doing column width changes:
>
> http://sniptools.com/databases/resize-a-column-in-a-postgresql-table-without-changing-data
>
> particularly in the case where the column is used in views etc, unless there is a down-side to using this approach?
>

I guess it may have some bad corner cases with cached plans and things
like that.

Why we don't do it in pgAdmin is quite simple:
1. nobody cares enough to write a patch for this
2. even if someone does, I don't feel comfortable commiting such a
patch.

I don't feel ready to commit such a patch because we have no guarantee
it'll work. It may work now and then (and only if you keep the same
datatype, but add more characters), but it's not guaranteed, hence the
fact that Tom asks the OP to do it in a transaction, to rollback in case
of trouble).

So, in a few words, too risky.

--
Guillaume
http://blog.guillaume.lelarge.info
http://www.dalibo.com

In response to

Browse pgadmin-support by date

  From Date Subject
Next Message Guillaume Lelarge 2011-09-24 14:44:30 Re: Dropping a type
Previous Message Guillaume Lelarge 2011-09-23 20:07:36 Re: pgadmin3 crash report