Re: changing field length - Mailing list pgsql-admin

From Jodi Kanter
Subject Re: changing field length
Date
Msg-id 3F4382C6.3030101@virginia.edu
Whole thread Raw
In response to changing field length  (Jodi Kanter <jkanter@virginia.edu>)
Responses Re: changing field length  (Bruno Wolff III <bruno@wolff.to>)
List pgsql-admin
how do I copy from one field to another?

Gaetano Mendola wrote:
"Jodi Kanter" <jkanter@virginia.edu> wrote:
I am running 7.3.3. Can I change a field that is varying character(128) 
to varying character(250)?

nope.

You can
a) create a new column named tmp of character(250).
b) copy the content from old column to new column
c) drop the old column
d) rename the tmp column to the correct name


Regards
Gaeatano Mendola

PS: Be carefull with the constraint....



---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faqs/FAQ.html

--

_______________________________
Jodi L Kanter
BioInformatics Database Administrator
University of Virginia
(434) 924-2846
jkanter@virginia.edu


 

 

 


pgsql-admin by date:

Previous
From: "Somasekhar Bangalore"
Date:
Subject: Need Help on query tuning
Next
From: Bruno Wolff III
Date:
Subject: Re: changing field length