public inbox for [email protected]  
help / color / mirror / Atom feed
From: Zhihong Yu <[email protected]>
To: Dmitry Koval <[email protected]>
Cc: PostgreSQL Hackers <[email protected]>
Subject: Re: Add SPLIT PARTITION/MERGE PARTITIONS commands
Date: Tue, 11 Oct 2022 10:15:05 -0700
Message-ID: <CALNJ-vRee1RmHgzV=-_B=6AN3L_CCuAjdzej5XxhfHR6iT2K5w@mail.gmail.com> (raw)
In-Reply-To: <CALNJ-vTgp527=NiduNv5Q42pY3zaUnJjTDEf1-=JcX6sZyGFRA@mail.gmail.com>
References: <[email protected]>
	<[email protected]>
	<CA+TgmoandAsE=Y=0UiYfP=Oyv7Fn2m717PWuPgFw8m9jQQbopg@mail.gmail.com>
	<[email protected]>
	<CALNJ-vTgp527=NiduNv5Q42pY3zaUnJjTDEf1-=JcX6sZyGFRA@mail.gmail.com>

On Tue, Oct 11, 2022 at 9:58 AM Zhihong Yu <[email protected]> wrote:

>
>
> On Tue, Oct 11, 2022 at 9:22 AM Dmitry Koval <[email protected]>
> wrote:
>
>> Hi!
>>
>> Fixed couple warnings (for cfbot).
>>
>> --
>> With best regards,
>> Dmitry Koval
>>
>> Postgres Professional: http://postgrespro.com
>
> Hi,
> For v12-0001-PGPRO-ALTER-TABLE-MERGE-PARTITIONS-command.patch:
>
> +       if (equal(name, cmd->name))
> +           /* One new partition can have the same name as merged
> partition. */
> +           isSameName = true;
>
> I think there should be a check before assigning true to isSameName - if
> isSameName is true, that means there are two partitions with this same name.
>
> Cheers
>

Pardon - I see that transformPartitionCmdForMerge() compares the partition
names.
Maybe you can add a comment in ATExecMergePartitions referring to
transformPartitionCmdForMerge() so that people can more easily understand
the logic.


view thread (163+ messages)  latest in thread

reply

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: [email protected]
  Cc: [email protected], [email protected], [email protected]
  Subject: Re: Add SPLIT PARTITION/MERGE PARTITIONS commands
  In-Reply-To: <CALNJ-vRee1RmHgzV=-_B=6AN3L_CCuAjdzej5XxhfHR6iT2K5w@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox