Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gjGEN-0000w9-UK for pgsql-hackers@arkaria.postgresql.org; Tue, 15 Jan 2019 04:21:40 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gjGEL-0007Xc-Hj for pgsql-hackers@arkaria.postgresql.org; Tue, 15 Jan 2019 04:21:37 +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_SHA1:256) (Exim 4.89) (envelope-from ) id 1gjGEL-0007XU-6h for pgsql-hackers@lists.postgresql.org; Tue, 15 Jan 2019 04:21:37 +0000 Received: from mail-qk1-x741.google.com ([2607:f8b0:4864:20::741]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gjGED-0002RG-Md for pgsql-hackers@postgresql.org; Tue, 15 Jan 2019 04:21:36 +0000 Received: by mail-qk1-x741.google.com with SMTP id a1so854705qkc.5 for ; Mon, 14 Jan 2019 20:21:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=2ndquadrant-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:mime-version:content-disposition :content-transfer-encoding:in-reply-to:user-agent; bh=C/SxxtnT38kt5EjcnSV//SuHPbjvCvVvkOLxF4FrGbo=; b=vnS7+Wtw0raQdfeUWieNwmqGblabsbaHVE50mQmxZPTpffx+zL4yuZ2uTqExlw3hoz 6v0uPmJcIpr4tcoZM8ni4kq+LfeeeYh3FHxJvssbeyvVxfP7Zn1FijIt9tfkYt5v1pO/ V44D45sb8o6MruFbEQJbgKKeTsEdgE0u2fzsrASKtPDvq1nxgGQmrabwwthV9lgmFag4 i5FUIx2YuDAM5sGx1KXBVhHY3/bLwNpPuWwPaxIvs2H3xJarvGYY3iw20M96jBBs0KEu mxfLiQQOLvyK1vkrd6fISxKAeJADNyA/RGRXbE1gImy+/WiWoh1woDUvjpSpXmCmDxTG XRPQ== 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:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=C/SxxtnT38kt5EjcnSV//SuHPbjvCvVvkOLxF4FrGbo=; b=Huhww7kCarm/JWahwCqtmhFWVxULvmdsioAHw6cD9WMQ569bAJReIKH9JCz9NMhtG3 LT3YiY6hRDtcSTP191uoZFz4Czw9dbPWsNkiLrIfKy8j4HJkaipc03gy5fs6DgqiG/1e QDoTNfuCrekKJeZx/pYvyChNtPiact4cG9Q89OaKAuUxf+kSMXRTZS3IaQBEO7VuQgCg X/0f50nhKQ8bicQv4e+/mh3INcVBGGTq3tvwQJE1XJotc/qyF5Bk8jDhMSYr8i1VawKy MQC04WdZ8BYCpx9selzFVg8y8TL0ehFWbud8/cpYN9apTeZg8QwMeEEgePAiBROaF+/Y xx2Q== X-Gm-Message-State: AJcUukcfCZzvb8RH6UTr5tmEIFzkLn0riwwm96R0v1VtOHFhxJg0E4vc 9zZMyY36AwPfec8oLN5FjTJ/JFWFMLH0FHw5tBaOi0jHf+DWr9lUhGBfASuYvvuX8d5NRaR0KjI xUNSjBtwKW8w2KgEHx37n8q2lztXloybQls0ePSz/RDRHaSx2Yd/LEVLDjWqnihZxFOSDmX0WIp 3eCNc2Ag== X-Google-Smtp-Source: ALg8bN4G31QNO+ysh4/yJsklocT5Wcm/35g9NJK/bCGytKvp8eWQ9IrpBbiwD/Obolt4cL++K7a0aA== X-Received: by 2002:a37:ac05:: with SMTP id e5mr1416656qkm.102.1547526087441; Mon, 14 Jan 2019 20:21:27 -0800 (PST) Received: from alvin.alvh.no-ip.org ([201.186.80.67]) by smtp.gmail.com with ESMTPSA id l33sm52358016qta.57.2019.01.14.20.21.26 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 14 Jan 2019 20:21:26 -0800 (PST) Received: by alvin.alvh.no-ip.org (Postfix, from userid 1000) id D8F1DAB1; Tue, 15 Jan 2019 01:21:24 -0300 (-03) Date: Tue, 15 Jan 2019 01:21:24 -0300 From: Alvaro Herrera To: Justin Pryzby Cc: pgsql-hackers@postgresql.org, Teodor Sigaev Subject: Re: unique, partitioned index fails to distinguish index key from INCLUDEd columns Message-ID: <201901150421.mlogf4cts5tj@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20190115023022.GJ15177@telsasoft.com> User-Agent: NeoMutt/20180716-1013-2c1e88 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 2019-Jan-14, Justin Pryzby wrote: > On Mon, Jan 14, 2019 at 07:31:07PM -0300, Alvaro Herrera wrote: > > Doh. Fix pushed. Commit 8224de4f42cc should have changed one > > appearance of ii_NumIndexAttrs to ii_NumIndexKeyAttrs, but because of > > the nature of concurrent development, nobody noticed. > > I figured as much - I thought to test this while trying to fall asleep, > without knowing they were developed in parallel. :-) > Should backpatch to v11 ? > 0ad41cf537ea5f076273fcffa4c83a184bd9910f Yep, already done (src/tools/git_changelog in master): Author: Alvaro Herrera Branch: master [0ad41cf53] 2019-01-14 19:28:10 -0300 Branch: REL_11_STABLE [74aa7e046] 2019-01-14 19:25:19 -0300 Fix unique INCLUDE indexes on partitioned tables We were considering the INCLUDE columns as part of the key, allowing unicity-violating rows to be inserted in different partitions. Concurrent development conflict in eb7ed3f30634 and 8224de4f42cc. Reported-by: Justin Pryzby Discussion: https://postgr.es/m/20190109065109.GA4285@telsasoft.com -- Álvaro Herrera https://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services