Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tfz8Q-006ktq-PJ for pgsql-hackers@arkaria.postgresql.org; Thu, 06 Feb 2025 10:29:27 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1tfz8P-0068GT-TY for pgsql-hackers@arkaria.postgresql.org; Thu, 06 Feb 2025 10:29:25 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tfz8P-0068GJ-IS for pgsql-hackers@lists.postgresql.org; Thu, 06 Feb 2025 10:29:25 +0000 Received: from fhigh-b3-smtp.messagingengine.com ([202.12.124.154]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1tfz8M-003rpB-13 for pgsql-hackers@lists.postgresql.org; Thu, 06 Feb 2025 10:29:25 +0000 Received: from phl-compute-12.internal (phl-compute-12.phl.internal [10.202.2.52]) by mailfhigh.stl.internal (Postfix) with ESMTP id E628D25400F6; Thu, 6 Feb 2025 05:29:20 -0500 (EST) Received: from phl-mailfrontend-02 ([10.202.2.163]) by phl-compute-12.internal (MEProxy); Thu, 06 Feb 2025 05:29:21 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :reply-to:subject:subject:to:to:x-me-proxy:x-me-sender :x-me-sender:x-sasl-enc; s=fm3; t=1738837760; x=1738924160; bh=r ybR5kIi+UAIN6IPX28Qke5QNDZ3U1MWR0eB7VMLUDw=; b=zOywA/mIGrSyKvjvH mbjIwt5/qjSpC8F5+LmigYwAy8ky2S9nVuUTHP99YS6ZfpLGWTmfRBe71R63gvXn GgR5VA89gMZ+B3y8XAZgCfYhCHbLlD2byoAowIvUL3CwbLST3NPi83xiZtASj3bZ RsJ8qR1cyYKE+k+zjAIPpEuVu8ffS27x49orliyKgYYyqqkiIX3hcjOH85kTvMj2 RCHCqaXwYI8RQnDGagOut16hN+st3cKBseQIz8fj2X3NK5hzY9K7yXdZKosNT7SH 5mTO1dgrKY9iKmU9SlhvF2SbjpoXbhdVzvOfWZ/IObWLlc7m28OUq+D729wlmA9l p4b3w== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefvddrtddtgddviedugecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdp uffrtefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivg hnthhsucdlqddutddtmdenucfjughrpeffhffvvefukfggtggugfgjsehtkeertddttdej necuhfhrohhmpemllhhvrghrohcujfgvrhhrvghrrgcuoegrlhhvhhgvrhhrvgesrghlvh hhrdhnohdqihhprdhorhhgqeenucggtffrrghtthgvrhhnpedvheeuffehgfeukeeufeeh hefghfeugfefudekjeevudffgeffkeegffffveegheenucffohhmrghinhepvghnthgvrh hprhhishgvuggsrdgtohhmnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehm rghilhhfrhhomheprghlvhhhvghrrhgvsegrlhhvhhdrnhhoqdhiphdrohhrghdpnhgspg hrtghpthhtohepfedpmhhouggvpehsmhhtphhouhhtpdhrtghpthhtohepiihmlhhpohhs thhgrhgvshesghhmrghilhdrtghomhdprhgtphhtthhopehpghhsqhhlqdhhrggtkhgvrh hssehlihhsthhsrdhpohhsthhgrhgvshhqlhdrohhrghdprhgtphhtthhopehmihgthhgr vghlsehprghquhhivghrrdighiii X-ME-Proxy: Feedback-ID: ia2694551:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 6 Feb 2025 05:29:19 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alvh.no-ip.org; s=schmee; t=1738837758; bh=PdUDUWptghBRAUzs/uwTRQW3LJEOtfC1O8CfR+tS8Ww=; h=Date:From:To:Cc:Subject:In-Reply-To:From; b=RuFV5SB8Xgdr64fleEayn6FTBZ4opHQ0g9Zvrw7yiJMZGZVMhpmszvGUFF3zX+nFA +MuDADYfoYQ8TXeL8zjC4jxlkR0+vEGkoJRvV8ghjhDLAYpxTSU/UTgYErvI0BNRGq fp0yLHyY8dnhOCuT4jd6y4uF5VQWb0UO1nww7V9dn7iCiJx+Y8irXpLvv5CyVEB3S9 DhnjiM5Oiw59VUTUPuGVf8E7uQNEtwpZXYu/FjjidpaQd4u8TPrYqWUxNXwEx1qs9F HsANFbX1HttA4KkRs7aRkLLHhKLsZwfhZuekbzD5yMsiZAT76jcYXwZhZoSjtBIjm4 VunlQHjoyRBag== Received: by schmee.alvh.no-ip.org (Postfix, from userid 1000) id 72C8C90; Thu, 6 Feb 2025 11:29:18 +0100 (CET) Date: Thu, 6 Feb 2025 11:29:18 +0100 From: =?utf-8?Q?=C3=81lvaro?= Herrera To: Zhang Mingli Cc: Michael Paquier , PostgreSQL Hackers Subject: Re: Proposal to CREATE FOREIGN TABLE LIKE Message-ID: <202502061029.s5sdtrnpfm7u@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <9324b4d3-d49f-463e-984a-2725fe36cb2b@Spark> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 2025-Feb-06, Zhang Mingli wrote: > Added support for CREATE FOREIGN TABLE LIKE to enable the creation of > foreign tables based on the column definitions, constraints of > existing source tables. > This feature mirrors the behavior of CREATE TABLE LIKE, but ignores > inapplicable options such as INCLUDING INDEXES and INCLUDING > COMPRESSION for foreign tables. I think it'd be better to throw errors if they are given -- but INCLUDING ALL should be made to work in a different way than today so that it doesn't raise errors uselessly. Right now it works by setting all the bits in the value, um. -- Álvaro Herrera PostgreSQL Developer — https://www.EnterpriseDB.com/