From: Igal @ Lucee.org <igal@lucee.org>
To: David G. Johnston <david.g.johnston@gmail.com>
Cc: pgsql-general <pgsql-general@postgresql.org>
Subject: Re: DDL and DML in a transaction
Date: Wed, 31 Jul 2019 12:57:32 -0700
Message-ID: <4c485a6f-9845-8d45-d902-b6d24f59856b@lucee.org> (raw)
In-Reply-To: <CAKFQuwZBy38L5X06WHMeFhMU03OmdSF8KTMMnJg6JLRu3=065g@mail.gmail.com>
References: <28ca745e-f459-95bd-bf80-7d907b65b9cf@lucee.org>
<CAKFQuwZBy38L5X06WHMeFhMU03OmdSF8KTMMnJg6JLRu3=065g@mail.gmail.com>
Thank you, David.
I should get more sleep...
Igal
On 7/31/2019 11:52 AM, David G. Johnston wrote:
> On Wed, Jul 31, 2019 at 11:38 AM Igal @ Lucee.org <igal@lucee.org
> <mailto:igal@lucee.org>> wrote:
>
> alter table some_table
> rename column amount_num to amount_text;
>
> alter table some_table
> drop column amount_num;
>
>
> You just renamed amount_num to amount_text so I'm not sure why you
> expect the drop to succeed.
>
> Would it have less locking than simply altering the column?
>
>
> I doubt anything will improve upon simply altering the column. You
> have to perform a full table rewrite in either case which is going to
> be the main resource consumer.
>
> David J.
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-general@postgresql.org
Cc: igal@lucee.org, david.g.johnston@gmail.com
Subject: Re: DDL and DML in a transaction
In-Reply-To: <4c485a6f-9845-8d45-d902-b6d24f59856b@lucee.org>
References: <28ca745e-f459-95bd-bf80-7d907b65b9cf@lucee.org> <CAKFQuwZBy38L5X06WHMeFhMU03OmdSF8KTMMnJg6JLRu3=065g@mail.gmail.com> <4c485a6f-9845-8d45-d902-b6d24f59856b@lucee.org>
* 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