From: Fujii Masao <masao.fujii@oss.nttdata.com>
To: Justin Pryzby <pryzby@telsasoft.com>
Cc: Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com>
Cc: Kohei KaiGai <kaigai@heterodb.com>
Cc: Kazutaka Onishi <onishi@heterodb.com>
Cc: Zhihong Yu <zyu@yugabyte.com>
Cc: Amit Langote <amitlangote09@gmail.com>
Cc: Ibrar Ahmed <ibrar.ahmad@gmail.com>
Cc: pgsql-hackers@lists.postgresql.org, Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>
Subject: Re: TRUNCATE on foreign table
Date: Tue, 13 Apr 2021 15:44:40 +0900
Message-ID: <e201283b-f246-1489-40d3-418ab0729fb2@oss.nttdata.com> (raw)
In-Reply-To: <20210413034637.GA6091@telsasoft.com>
References: <d5df2e94-f643-6409-5cd4-fa1c2ebd41fa@oss.nttdata.com>
<CAOP8fzbKh1V_n-huDmzxQRsMRZ5qNb+2wo5khKOrweGgx6pBrg@mail.gmail.com>
<43f71643-5068-8a77-4bda-005b0ff7bd4f@oss.nttdata.com>
<CAOP8fzYY=xkj_ke3h-cHO08S6WKfcja0uNPmGjNYo50rm66+6Q@mail.gmail.com>
<551ed8c1-f531-818b-664a-2cecdab99cd8@oss.nttdata.com>
<20210411041658.GB14564@telsasoft.com>
<CALj2ACU2ZF2SLuU4UCXAPzCyb+=Anhtgp3VhWmKPHAGC3yFeHg@mail.gmail.com>
<20210413005726.GK20530@telsasoft.com>
<CALj2ACUt74VnVA_7dkEbo00eJQah9GObvomp-_fJr2NM=kfd0g@mail.gmail.com>
<bf469e1b-d500-9f0d-36fc-e9515594f3bf@oss.nttdata.com>
<20210413034637.GA6091@telsasoft.com>
On 2021/04/13 12:46, Justin Pryzby wrote:
> On Tue, Apr 13, 2021 at 12:38:35PM +0900, Fujii Masao wrote:
>> + <structname>Relation</structname> data structures for each
>> + foreign tables to be truncated.
>>
>> "foreign tables" should be "foreign table" because it follows "each"?
>
> Yes, you're right.
>
>> + <para>
>> + <literal>behavior</literal> is either
>> + <literal>DROP_RESTRICT</literal> or <literal>DROP_CASCADE</literal>.
>> + <literal>DROP_CASCADE</literal> indicates that the
>> + <literal>CASCADE</literal> option was specified in the original
>> <command>TRUNCATE</command> command.
>>
>> Why did you remove the description for DROP_RESTRICT?
>
> Because in order to handle the default/unspecified case, the description was
> going to need to be something like:
>
> | DROP_RESTRICT indicates that the RESTRICT option was specified in the original
> | truncate command (or CASCADE option was NOT specified).
What about using "requested" instead of "specified"? If neither RESTRICT nor
CASCADE is specified, we can think that user requested the default behavior,
i.e., RESTRICT. So, for example,
<literal>behavior</literal> is either <literal>DROP_RESTRICT</literal> or
<literal>DROP_CASCADE</literal>, which indicates that the
<literal>RESTRICT</literal> or <literal>CASCADE</literal> option was
requested in the original <command>TRUNCATE</command> command, respectively.
Regards,
--
Fujii Masao
Advanced Computing Technology Center
Research and Development Headquarters
NTT DATA CORPORATION
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-hackers@postgresql.org
Cc: masao.fujii@oss.nttdata.com, pryzby@telsasoft.com, bharath.rupireddyforpostgres@gmail.com, kaigai@heterodb.com, onishi@heterodb.com, zyu@yugabyte.com, amitlangote09@gmail.com, ibrar.ahmad@gmail.com, ashutosh.bapat.oss@gmail.com
Subject: Re: TRUNCATE on foreign table
In-Reply-To: <e201283b-f246-1489-40d3-418ab0729fb2@oss.nttdata.com>
References: <d5df2e94-f643-6409-5cd4-fa1c2ebd41fa@oss.nttdata.com> <CAOP8fzbKh1V_n-huDmzxQRsMRZ5qNb+2wo5khKOrweGgx6pBrg@mail.gmail.com> <43f71643-5068-8a77-4bda-005b0ff7bd4f@oss.nttdata.com> <CAOP8fzYY=xkj_ke3h-cHO08S6WKfcja0uNPmGjNYo50rm66+6Q@mail.gmail.com> <551ed8c1-f531-818b-664a-2cecdab99cd8@oss.nttdata.com> <20210411041658.GB14564@telsasoft.com> <CALj2ACU2ZF2SLuU4UCXAPzCyb+=Anhtgp3VhWmKPHAGC3yFeHg@mail.gmail.com> <20210413005726.GK20530@telsasoft.com> <CALj2ACUt74VnVA_7dkEbo00eJQah9GObvomp-_fJr2NM=kfd0g@mail.gmail.com> <bf469e1b-d500-9f0d-36fc-e9515594f3bf@oss.nttdata.com> <20210413034637.GA6091@telsasoft.com> <e201283b-f246-1489-40d3-418ab0729fb2@oss.nttdata.com>
* 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