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 1nlT82-00013H-2V for pgsql-hackers@arkaria.postgresql.org; Mon, 02 May 2022 10:18:06 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1nlT7z-00045D-Fv for pgsql-hackers@arkaria.postgresql.org; Mon, 02 May 2022 10:18:03 +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 1nlT7y-000454-Rr for pgsql-hackers@lists.postgresql.org; Mon, 02 May 2022 10:18:03 +0000 Received: from wnew4-smtp.messagingengine.com ([64.147.123.18]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nlT7w-0005aT-6Y for pgsql-hackers@lists.postgresql.org; Mon, 02 May 2022 10:18:01 +0000 Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailnew.west.internal (Postfix) with ESMTP id 4B16E2B011F0; Mon, 2 May 2022 06:17:57 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Mon, 02 May 2022 06:17:57 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:date:date:from:from:in-reply-to:in-reply-to :message-id:mime-version:reply-to:sender:subject:subject:to:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; t=1651486676; x=1651493876; bh=qld2S6aONwNX8wHttxXDyTo4VATk 50Y98ofr9nPki4g=; b=uxtoYtCUi5HgCOKdr6DktadzMI7PRY/mt+0ClLynGjkw DgKkmycMue0S69JJ0tQOa3ZSazyD/xJfuOhB8WE6gzN4xM+qEAFljVlutsXR2rY6 kSocXc3fbrdNQhMF5IRRxK+q0ZPnNN7lzNN+XQ99xPHKEgHOfrvbSv3829S7BffS uPoEAF/yhheJTSSkbUZWl6BMRWcmqEvmuBgndJZV3/9twcOPBdr8sDBrAQU5kLaK Gmc6qV9qJ5WozZ9eSDgsZJfj2xvwT5GaEHRdJ1pLFkQXD6zdVwabue117jwGiV5S UbL5Gp240Y/MUJo1JcuhUZigm2zVK1l3/hsPz+1OPg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvfedrvdehgddvhecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenog fuphgrmhdqkffkrffuuhhmmhgvrhculdehuddvmdenucfjughrpeffhffvvefukfggtggu gfgjsehtkeertddttdejnecuhfhrohhmpeetlhhvrghrohcujfgvrhhrvghrrgcuoegrlh hvhhgvrhhrvgesrghlvhhhrdhnohdqihhprdhorhhgqeenucggtffrrghtthgvrhhnpedv kedtffduffdtffffheffhfejjefhgfeiueeukeejkeffgfdufffhudffffeuveenucffoh hmrghinhepvghnthgvrhhprhhishgvuggsrdgtohhmnecuvehluhhsthgvrhfuihiivgep tdenucfrrghrrghmpehmrghilhhfrhhomheprghlvhhhvghrrhgvsegrlhhvhhdrnhhoqd hiphdrohhrgh X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 2 May 2022 06:17:56 -0400 (EDT) Received: by perhan.alvh.no-ip.org (Postfix, from userid 1000) id 25BA02A07D2; Mon, 2 May 2022 12:17:54 +0200 (CEST) Date: Mon, 2 May 2022 12:17:54 +0200 From: Alvaro Herrera To: Tomas Vondra Cc: Amit Kapila , Peter Eisentraut , Pg Hackers Subject: Re: bogus: logical replication rows/cols combinations Message-ID: <202205021017.himfy7asanau@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <7fdf7ac3-912b-f450-f9c1-aa239df4ac1a@enterprisedb.com> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 2022-May-02, Tomas Vondra wrote: > On 5/2/22 07:31, Amit Kapila wrote: > > Yeah, or don't allow to define such publications in the first place so > > that different subscriptions can't combine them but I guess that might > > forbid some useful cases as well where publication may not get > > combined with other publications. > > But how would you check that? You don't know which publications will be > combined by a subscription until you create the subscription, right? ... and I think this poses a problem: if the publisher has multiple publications and the subscriber later uses those to create a combined subscription, we can check at CREATE SUBSCRIPTION time that they can be combined correctly. But if the publisher decides to change the publications changing the rules and they are no longer consistent, can we throw an error at ALTER PUBLICATION point? If the publisher can detect that they are being used together by some subscription, then maybe we can check consistency in the publication side and everything is all right. But I'm not sure that the publisher knows who is subscribed to what, so this might not be an option. The latter ultimately means that we aren't sure that a combined subscription is safe. And in turn this means that a pg_dump of such a database cannot be restored (because the CREATE SUBSCRIPTION will be rejected as being inconsistent). -- Álvaro Herrera 48°01'N 7°57'E — https://www.EnterpriseDB.com/