RE: [bug fix] ALTER TABLE SET LOGGED/UNLOGGED on a partitioned table does nothing silently

From: "tsunakawa(dot)takay(at)fujitsu(dot)com" <tsunakawa(dot)takay(at)fujitsu(dot)com>
To: 'Alvaro Herrera' <alvherre(at)alvh(dot)no-ip(dot)org>
Cc: 'Bharath Rupireddy' <bharath(dot)rupireddyforpostgres(at)gmail(dot)com>, "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: RE: [bug fix] ALTER TABLE SET LOGGED/UNLOGGED on a partitioned table does nothing silently
Date: 2020-12-09 04:23:39
Message-ID: TYAPR01MB2990BFBF8172C18627E55A88FECC0@TYAPR01MB2990.jpnprd01.prod.outlook.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

From: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
> But what happens when you create another partition after you change the
> "loggedness" of the partitioned table?

The new partition will have a property specified when the user creates it. That is, while the storage property of each storage unit (=partition) is basically independent, ALTER TABLE on a partitioned table is a convenient way to set the same property value to all its underlying storage units.

> Well, my main take from that is we should strive to change all
> subcommands together, in some principled way, rather than change only
> one or some, in arbitrary ways.

I got an impression from the discussion that some form of consensus on the principle was made and you were trying to create a fix for REPLICA IDENTITY. Do you think the principle was unclear and we should state it first (partly to refresh people's memories)?

I'm kind of for it, but I'm hesitant to create the fix for all ALTER actions, because it may take a lot of time and energy as you were afraid. Can we define the principle, and then create individual fixes independently based on that principle?

Regards
Takayuki Tsunakawa

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2020-12-09 04:36:04 Re: small cleanup in unicode_norm.c
Previous Message Shinya11.Kato 2020-12-09 03:57:55 [PATCH] Feature improvement for CLOSE, FETCH, MOVE tab completion