Re: Minor correction in alter_table.sgml

From: Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Stephen Frost <sfrost(at)snowman(dot)net>
Cc: Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Minor correction in alter_table.sgml
Date: 2016-12-01 01:47:35
Message-ID: a867a959-c119-ef4f-8ea6-20689983eb79@lab.ntt.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2016/12/01 1:17, Tom Lane wrote:
> Stephen Frost <sfrost(at)snowman(dot)net> writes:
>> Seems like this would be a bit better:
>
>> ------
>> All the actions, when acting on a single table and not using the ALL IN
>> TABLESPACE form, except RENAME and SET SCHEMA, can be combined into a
>> list of multiple alterations to be applied.
>> ------
>
>> I note that we say 'in parallel', but given that we have actual parallel
>> operations now, we should probably shy away from using that except in
>> cases where we actually mean operations utilizing multiple parallel
>> processes.
>
> I follow your beef with use of the word "parallel", but your proposed
> rewording loses the entire point of multiple actions per ALTER TABLE;
> namely that they're accomplished without repeated scans of the table.
>
> Also the above seems a bit clunky; doesn't ALL IN TABLESPACE fall outside
> the restriction "acting on a single table"?
>
> So maybe something like
>
> All the forms of ALTER TABLE that act on a single table,
> except RENAME and SET SCHEMA, can be combined into a
> list of multiple alterations to be applied together.

Updated patch attached.

> We would have to enlarge on what "together" means, but I think there may
> already be text explaining that further down.

There is this explanation:

<para>
The main reason for providing the option to specify multiple changes
in a single <command>ALTER TABLE</> is that multiple table scans or
rewrites can thereby be combined into a single pass over the table.
</para>

Thanks,
Amit

Attachment Content-Type Size
doc-alter-table-fix-2.patch text/x-diff 1.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2016-12-01 01:48:26 pgcrypto compilation error due to stack-allocated EVP_CIPHER_CTX
Previous Message Ian Barwick 2016-12-01 01:45:51 monitoring.sgml - clarify length of query text displayed in pg_stat_statements