Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lWA0i-00011F-WF for pgsql-hackers@arkaria.postgresql.org; Tue, 13 Apr 2021 03:46:45 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lWA0h-0007uf-Qt for pgsql-hackers@arkaria.postgresql.org; Tue, 13 Apr 2021 03:46:43 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lWA0h-0007uY-G8 for pgsql-hackers@lists.postgresql.org; Tue, 13 Apr 2021 03:46:43 +0000 Received: from mail-io1-xd2f.google.com ([2607:f8b0:4864:20::d2f]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1lWA0e-0000bS-Nj for pgsql-hackers@lists.postgresql.org; Tue, 13 Apr 2021 03:46:42 +0000 Received: by mail-io1-xd2f.google.com with SMTP id a9so4841182ioc.8 for ; Mon, 12 Apr 2021 20:46:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telsasoft-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=AG8AIoLR8TtzHi2zs7VQjZUFFMh+NSTb1VGH1B/O+yY=; b=Z8EkDZEdmCt5r1hHze9OyigeWpw8txobC8+BWh4mEPRxemzaJAX0f3kUTnlXuTN2YV RoXEGzero1BcXTRSnE6tM7jaIfUFaj7ljwPQfdv8Wg1aKCRlpUOgt70RetwjPKuyKGWq oGKuh4XbVBcmiCgymKg2jvPW4uu2+YUoK8dxg/HzyEGIyU4ryHrHiMjJa3G3lcKcnIM5 IXUCRPk+nt4w+SrJBPr8QYWm/XM9CqFt0LepOAzdAeSX1CAUr8VC2JNrIvY/tAJD0dtj XqI9p3lGQkGVk8tj2wLBjoBI7X8yJ0u5x8MuXF4mgp8uKH/k2PcLQewO/9G2Se63CUJf 4Uog== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=AG8AIoLR8TtzHi2zs7VQjZUFFMh+NSTb1VGH1B/O+yY=; b=unvUes7XsX/aZxWxOXp0kxFbR0GJwxvEWRlY/rffeUeJyIVPOKkWa64sDIbj35B5lS Uf+6l1KceWC6It8n1Owsz94CQjs3ZgD4ldQdt7fyyAPplnqbEiHB+mlARWhy0pS+YVQ5 Lo3aVyqy2Sdro7AmLWZcfe4+Kbg2wOk6lYVuh4z2fPiumJY7YC8U+i/5mIucq3fxhC7w 7zdUWiktkKo5zDDjC6exiKJckzsPfQfsqAJxBFidbzAN7yP+eB3b5dA/PHTN4+3Rqdp5 gXuj5VmpqNqgB9+2u/e+wFxp/E6BK4KX8D98TGazD/nlf1W6ivIkWSSEhBbT4JqBxSli c71g== X-Gm-Message-State: AOAM5323eUNZ23U9KwHMH4IuO3+VVe+wHTYuTxOjOyd2ntaVfM5OVfGM QkfoVol7vmedAA5m24L57UFH+g== X-Google-Smtp-Source: ABdhPJwx4jgv7G/YzjONWgWiwdb5bEWk19mdkOqw+F9gJv3/j10V9xT+wHN7EUYAwQwgm/DzCZkWlQ== X-Received: by 2002:a05:6638:140e:: with SMTP id k14mr30821337jad.31.1618285599582; Mon, 12 Apr 2021 20:46:39 -0700 (PDT) Received: from pryzbyj.telsasoft (charmander.telsasoft.com. [50.244.222.1]) by smtp.gmail.com with ESMTPSA id e6sm6447165ilr.81.2021.04.12.20.46.38 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 12 Apr 2021 20:46:39 -0700 (PDT) Received: by pryzbyj.telsasoft (Postfix, from userid 1000) id 03690801A44; Mon, 12 Apr 2021 22:46:37 -0500 (CDT) Date: Mon, 12 Apr 2021 22:46:37 -0500 From: Justin Pryzby To: Fujii Masao Cc: Bharath Rupireddy , Kohei KaiGai , Kazutaka Onishi , Zhihong Yu , Amit Langote , Ibrar Ahmed , pgsql-hackers@lists.postgresql.org, Ashutosh Bapat Subject: Re: TRUNCATE on foreign table Message-ID: <20210413034637.GA6091@telsasoft.com> References: <43f71643-5068-8a77-4bda-005b0ff7bd4f@oss.nttdata.com> <551ed8c1-f531-818b-664a-2cecdab99cd8@oss.nttdata.com> <20210411041658.GB14564@telsasoft.com> <20210413005726.GK20530@telsasoft.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.4 (2018-02-28) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Tue, Apr 13, 2021 at 12:38:35PM +0900, Fujii Masao wrote: > + Relation data structures for each > + foreign tables to be truncated. > > "foreign tables" should be "foreign table" because it follows "each"? Yes, you're right. > + > + behavior is either > + DROP_RESTRICT or DROP_CASCADE. > + DROP_CASCADE indicates that the > + CASCADE option was specified in the original > TRUNCATE 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). -- Justin