From: Nick Fankhauser <nickf@ontko.com>
To: Jodi Kanter <jkanter@virginia.edu>
To: Postgres Admin List <pgsql-admin@postgresql.org>
Subject: Re: changing field length
Date: Tue, 19 Aug 2003 19:37:38 -0500
Message-ID: <NEBBLAAHGLEEPCGOBHDGGEJLIAAA.nickf@ontko.com> (raw)
In-Reply-To: <3F426DB0.1040607@virginia.edu>
Jodi-
Here's an example of the "hack" approach, which I've used without causing
any problems for some time:
update pg_attribute set atttypmod = 104
where attrelid = ( select oid from pg_class where relname = 'actor'
and attname = 'actor_full_name' );
In your case, you'd substitute 254 for 104, your table name for "actor" and
your field name for "actor_full_name";
-Nick
-----Original Message-----
From: pgsql-admin-owner@postgresql.org
[mailto:pgsql-admin-owner@postgresql.org]On Behalf Of Jodi Kanter
Sent: Tuesday, August 19, 2003 1:34 PM
To: Postgres Admin List
Subject: [ADMIN] changing field length
I am running 7.3.3. Can I change a field that is varying character(128) to
varying character(250)?
Thanks
Jodi
--
_______________________________
Jodi L Kanter
BioInformatics Database Administrator
University of Virginia
(434) 924-2846
jkanter@virginia.edu
<!--[if !supportLineBreakNewLine]-->
<!--[endif]-->
<!--[if !supportEmptyParas]--> <!--[endif]-->
<!--[if !supportEmptyParas]--> <!--[endif]-->
<!--[if !supportEmptyParas]--> <!--[endif]-->
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-admin@postgresql.org
Cc: nickf@ontko.com, jkanter@virginia.edu
Subject: Re: changing field length
In-Reply-To: <NEBBLAAHGLEEPCGOBHDGGEJLIAAA.nickf@ontko.com>
References: <3F426DB0.1040607@virginia.edu> <NEBBLAAHGLEEPCGOBHDGGEJLIAAA.nickf@ontko.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox