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 1ry2TQ-00ECIy-H4 for pgsql-hackers@arkaria.postgresql.org; Sat, 20 Apr 2024 04:37:12 +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 1ry2TO-007vjG-95 for pgsql-hackers@arkaria.postgresql.org; Sat, 20 Apr 2024 04:37:10 +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 1ry2TN-007vj7-96 for pgsql-hackers@lists.postgresql.org; Sat, 20 Apr 2024 04:37:09 +0000 Received: from m16.mail.163.com ([117.135.210.3]) by magus.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1ry2TC-001vEi-4g for pgsql-hackers@lists.postgresql.org; Sat, 20 Apr 2024 04:37:07 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=From:Subject:Date:Message-ID:MIME-Version: Content-Type; bh=0kjFIaItpOZWRy8TG186AwtFoDzVuuof+ipwBLJ6ixk=; b=G2JZ5g/I0b27DJvqDvYTItXrXWsG7lgc0i8LWxlmtBrgMo0MzCoSGGvgke9r/D VCmrG51f5GZm+JJiwBdO+xYpa0i6fFAU5d2Dm3V779Od6RZU1uGVqaQuVpZTxZB1 sxZBcfm9bsV21mBuq1r3ojkirTaP2NpjKJa/eSdIytwGE= Received: from 8235eee8a2a0 (unknown [140.205.118.4]) by gzga-smtp-mta-g3-2 (Coremail) with SMTP id _____wD3f_1SRiNmHVLmBg--.34150S3; Sat, 20 Apr 2024 12:36:35 +0800 (CST) References: <7mlamswjp81p.fsf@e18c07352.et15sqa> <871qczm9oc.fsf@163.com> <7971.1713526758@antos> User-agent: mu4e 1.10.7; emacs 29.1 From: Andy Fan To: Antonin Houska Cc: PostgreSQL Hackers , David Rowley , Tom Lane , Ashutosh Bapat , jian he Subject: Re: UniqueKey v2 Date: Sat, 20 Apr 2024 12:19:02 +0800 In-reply-to: <7971.1713526758@antos> Message-ID: <87cyqklkfh.fsf@163.com> MIME-Version: 1.0 Content-Type: text/plain X-CM-TRANSID:_____wD3f_1SRiNmHVLmBg--.34150S3 X-Coremail-Antispam: 1Uf129KBjvJXoW7Cry7Xw4xCF4fJF43Jw47urg_yoW8Gr1xpF W8Ka1Skr4DJrWxCFs7WF48try0g34rJrWUWr1fWryUZ3Z8Ww1xtryF9F4Y9FykWrsxKryF vanavr95ua1qyFJanT9S1TB71UUUUU7qnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDUYxBIdaVFxhVjvjDU0xZFpf9x0zRpVbQUUUUU= X-Originating-IP: [140.205.118.4] X-CM-SenderInfo: x2klx3xlid0iqsrtqiywtou0bp/xtbBzxTGU2V4IxB6EwAAsJ List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hello Antonin, > zhihuifan1213@163.com wrote: > >> Here is the v3, ... > > I'm trying to enhance the join removal functionality (will post my patch in a > separate thread soon) and I consider your patch very helpful in this > area. Thanks for these words. The point 2) and 3) is pretty interesting to me at [1] and "enhance join removal" is another interesting user case. > Following is my review. Attached are also some fixes and one enhancement: > propagation of the unique keys (UK) from a subquery to the parent query > (0004). (Note that 0001 is just your patch rebased). Thanks for that! more enhancment like uniquekey in partitioned table is needed. This post is mainly used to check if more people is still interested with this. > Are you going to submit the patch to the first CF of PG 18? Since there are still known work to do, I'm not sure if it is OK to submit in CF. What do you think about this part? > > Please let me know if I can contribute to the effort by reviewing or writing > some code. Absolutely yes! please feel free to review / writing any of them and do remember add yourself into the author list if you do that. Thanks for your review suggestion, I will get to this very soon if once I get time, I hope it is in 4 weeks. [1] https://www.postgresql.org/message-id/7mlamswjp81p.fsf%40e18c07352.et15sqa -- Best Regards Andy Fan