Re: [1.4rc1] Can't change column type

From: Chris <chris(dot)velevitch(at)gmail(dot)com>
To: pgadmin-support(at)postgresql(dot)org
Subject: Re: [1.4rc1] Can't change column type
Date: 2005-11-06 08:36:38
Message-ID: loom.20051106T093353-28@post.gmane.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-support

Joost Kraaijeveld <J.Kraaijeveld <at> Askesis.nl> writes:
> Does this work (replace the names according to your schema)?
>
> BEGIN;
> ALTER TABLE table_name ADD COLUMN new_column varchar(64)?;
> UPDATE table_name SET new_column = column;
> ALTER TABLE customer RENAME column TO old_column;
> ALTER TABLE customer RENAME new_column TO columns;
> COMMIT;

In the end, I did this plu I dropped the old column, but what's the point of
having a tool like pgAdmin if common place everyday activities like this can't
be done?

In response to

Responses

Browse pgadmin-support by date

  From Date Subject
Next Message Joost Kraaijeveld 2005-11-06 08:52:42 Re: [1.4rc1] Can't change column type
Previous Message Joost Kraaijeveld 2005-11-06 08:20:34 Re: [1.4rc1] Can't change column type