Re: full featured alter table?

From: Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com>
To: Sven Koehler <skoehler(at)upb(dot)de>
Cc: <pgsql-general(at)postgresql(dot)org>
Subject: Re: full featured alter table?
Date: 2003-06-12 14:44:13
Message-ID: 20030612074037.J25608-100000@megazone23.bigpanda.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


On Thu, 12 Jun 2003, Sven Koehler wrote:

> one of the biggest disease of PostGreSQL is, that i can't change the
> definition of a column.
>
> In order to do that, i'd have to drop any keys, drop the column and
> create a new one with all indexes etc.
>
> Are there any plans to overcome that problem?

Pretty much when someone who cares about it enough comes along with
a sufficient plan (and preferrably code) to implement it without breaking
things would be my guess (especially given that AFAICS it's not part of
either SQL92 or SQL99). Note that a sufficient plan would possibly
involve a lot of things not directly involved with changing the type
such as being able to deal with cached query plans for functions and
such.

> Even simple changes like varchar(20) to varchar(200) are not allowed.

True, but at least these are simple manipulations of the system catalog.

> So my DB is planned well, but i have to change it every now and than
> because i must implement the changes that my client demands me to do,
> and have some extra work that nobody will pay me for, if there's no way
> to change a column.

Why? If your client asks for a change, they should pay for what's
involved. You have to make it known that changes are more costly for
this setup up front, but if it has other advantages, they can choose
which way to go.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Ian Barwick 2003-06-12 14:49:45 Re: Postgres performance comments from a MySQL user
Previous Message Sven Koehler 2003-06-12 14:33:11 Re: full featured alter table?