From: Tom Lane <tgl@sss.pgh.pa.us>
To: Andreas Berger <4postgres@gmail.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: alter table without an ACCESS EXCLUSIVE lock
Date: Thu, 16 Jun 2011 14:21:40 -0400
Message-ID: <6559.1308248500@sss.pgh.pa.us> (raw)
In-Reply-To: <BANLkTinQhc4kDmovgYB00TtrYF4+k9XZ-g@mail.gmail.com>
References: <BANLkTinQhc4kDmovgYB00TtrYF4+k9XZ-g@mail.gmail.com>
Andreas Berger <4postgres@gmail.com> writes:
> i'm searching for a solution for changing the type of a column, e.g. from
> varchar(128) to varchar(512), without an ACCESS EXCLUSIVE lock.
That specific case (increasing the max length of a varchar column) could
be handled by hacking the pg_attribute.atttypmod entry for the column,
since no change in the actual data is required.
However, I have no idea whether your replication environment would cope
with such a change --- experimenting on a non-production setup would be
highly recommendable.
regards, tom lane
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 using the --to and --cc options:
reply via email
To: pgsql-admin@postgresql.org
Cc: tgl@sss.pgh.pa.us, 4postgres@gmail.com
Subject: Re: alter table without an ACCESS EXCLUSIVE lock
In-Reply-To: <6559.1308248500@sss.pgh.pa.us>
* 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