Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1ezB63-0001s1-7C for pgsql-hackers@arkaria.postgresql.org; Fri, 23 Mar 2018 01:02:19 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1ezB60-0003Cu-54 for pgsql-hackers@arkaria.postgresql.org; Fri, 23 Mar 2018 01:02:16 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1ezB5z-0003Ck-OR for pgsql-hackers@lists.postgresql.org; Fri, 23 Mar 2018 01:02:15 +0000 Received: from new1-smtp.messagingengine.com ([66.111.4.221]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1ezB5v-0007SY-Ga for pgsql-hackers@postgresql.org; Fri, 23 Mar 2018 01:02:15 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailnew.nyi.internal (Postfix) with ESMTP id C7F4816A2; Thu, 22 Mar 2018 21:02:09 -0400 (EDT) Received: from frontend1 ([10.202.2.160]) by compute4.internal (MEProxy); Thu, 22 Mar 2018 21:02:09 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:subject:to :x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=JhjAEadIeputNGgDJ Yd6htMiM2gCrheGuIbK4Zx1vKQ=; b=GXszqLxN8z23KwA6EJrWGaiMgvMsdW7dA c1MiYdc29uJUMmNQ9N+Qktyn70JtEX8z0jf2jZAF6Z/GUdgI4TmuRvDgnz7FB2sH E9qpWaPjW2346I4ACr8vz9fzB//qJl47ePhqfsj+4wUUQZ9cil7YxnO0+etok8zQ LlTRWmARvHkB8bOr0rS7ijs4c2AzDixXxiLS7xyFKei91/42xtKwujLSTvyXGa+V VOFv4frYk1dZAg1dksWfGouB6YCobm3k799PaylS0d6blATAPZt4l1BjzuI3NwdV 1M6Ec0WuzX794lp9XN8ydO7pvBlqlb+2e3Uqerrwl5hAKHQdPkZkA== X-ME-Sender: Received: from alvin.alvh.no-ip.org (unknown [190.121.34.242]) by mail.messagingengine.com (Postfix) with ESMTPA id 367B17E0D6; Thu, 22 Mar 2018 21:02:09 -0400 (EDT) Received: by alvin.alvh.no-ip.org (Postfix, from userid 1000) id 9FE065A1; Thu, 22 Mar 2018 22:02:06 -0300 (-03) Date: Thu, 22 Mar 2018 22:02:06 -0300 From: Alvaro Herrera To: Peter Geoghegan Cc: Simon Riggs , Pavan Deolasee , Robert Haas , Tomas Vondra , Andrew Dunstan , Pavan Deolasee , Stephen Frost , PostgreSQL-development Subject: Re: [HACKERS] MERGE SQL Statement for PG11 Message-ID: <20180323010206.vjk7onhdoo7ptv7m@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: NeoMutt/20170306-137-4415bd-dirty (1.8.0) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Peter Geoghegan wrote: > Pavan hasn't added support for referencing CTEs, which other database > systems with MERGE have. I think that it ought to be quite doable. It > didn't take me long to get it working myself, but there wasn't follow > through on that (I could have posted the patch, which looked exactly > as you'd expect it to look). I think that we should add support for > CTEs now, as I see no reason for the omission. Incremental development is a good thing. Trying to do everything in a single commit is great when time is infinite or even merely very long, but if you run out of it, which I'm sure is common, leaving some things out that can be reasonable implemented in a separate patch is perfectly acceptable. -- Álvaro Herrera https://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services