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 1k6hOy-0007id-6s for pgsql-hackers@arkaria.postgresql.org; Fri, 14 Aug 2020 21:38:16 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1k6hOx-0002CX-6v for pgsql-hackers@arkaria.postgresql.org; Fri, 14 Aug 2020 21:38:15 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k6hMT-00070X-TZ for pgsql-hackers@lists.postgresql.org; Fri, 14 Aug 2020 21:35:42 +0000 Received: from mail-qt1-x843.google.com ([2607:f8b0:4864:20::843]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1k6hMR-0006us-7f for pgsql-hackers@lists.postgresql.org; Fri, 14 Aug 2020 21:35:41 +0000 Received: by mail-qt1-x843.google.com with SMTP id v22so8046641qtq.8 for ; Fri, 14 Aug 2020 14:35:39 -0700 (PDT) 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=XlGfYIB6CRDmbuW01RktgAK3vx8Gmq3IH3Rk67gcDqE=; b=gbHV/vrfMSUVMo98c5lsUJtlONItPs3CI1K0XAqlMbcS+yvBGRpoVp1YUgkN8fvqEV j54dfE5FD0BCILEswdz73YfRCTY5y38OTEQeMqpBn4q4MLZo7Y+P580MDrhsxyiAqfwt JJlPz84kPv6EEbtprwJrYEcVE3dQKCl0tR3pDqLVJEiJo9gL5uJCuVFALybv2JAcHpI8 B/0uukjp+6MS7kEgS4WSB2hqvuirxAegL4XTGKPjqGqtrqYFh5rbF+lIZ2E9RJss97h3 50KyllDJCca2HSQBc4ydWf3Et4EUyISxdcaPaIPBKUvJJ5WCKTBaqOrkJpxtPZ/0CYOS yLfg== 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=XlGfYIB6CRDmbuW01RktgAK3vx8Gmq3IH3Rk67gcDqE=; b=A3PWe71nzBU0wuQ+Hg7dQB8t5rGNfJpXX8pvSVbbPVwlPfeqm1ejGQ/hLr1hr/tVku PuO/K/rX62fgJbu5vYrYjWf4dC4kQSg+kUUDDkTMZNVOdg3/J2Em8e5ElhsLghVNIKti /ek83aI09GUR8wsvnZlLdpuDfRjVnEzLfyTZhVbkMw1/TaTrrDP9uJf4ri09j0PnNIX4 9d7JHE1fXjvLtwvAtb8lc7F/HSIQDnWpM0MzZre7ObAotWd96+G5WP1K3FLF+ol1B405 4ZjknFIqG8ld5gOPamub3QHquUnN41BgJQR93zxKinmofLqHKvcFr2G7PmbES8+2svJ7 /pbQ== X-Gm-Message-State: AOAM5315PYQDKli3CozWvtACAWRWsHcGAVxRAuX12ecRtb+znrzeXPIQ BpJCuJfahNWRQM7GN/4NJNmhvrdcNzsxDwrsgSD9i490epW4mEUso7VBxxcQhSH+RItExD+T3qs QtYaKPJggzBgdFcRj7moQg7AMC43lRNCCfFxcYu9fDyopd1xbfugevICtoWpZX+0cRjEtvTSA2W IMw6IlADWFhizRCLir X-Google-Smtp-Source: ABdhPJzHR49k8Bntq1/CR8F/HksUl2/JxnM3T/69zFdRIlLa2JsmHfR6dBe3g02u7J/SpFWO8Z5TgA== X-Received: by 2002:ac8:c0e:: with SMTP id k14mr4096811qti.364.1597440937586; Fri, 14 Aug 2020 14:35:37 -0700 (PDT) Received: from perhan.alvh.no-ip.org ([190.95.19.47]) by smtp.gmail.com with ESMTPSA id 103sm10863412qta.31.2020.08.14.14.35.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 14 Aug 2020 14:35:36 -0700 (PDT) Received: by perhan.alvh.no-ip.org (Postfix, from userid 1000) id C4E7B2A0FD5; Fri, 14 Aug 2020 17:35:34 -0400 (-04) Date: Fri, 14 Aug 2020 17:35:34 -0400 From: Alvaro Herrera To: Tom Lane Cc: pgsql-hackers@lists.postgresql.org Subject: Re: Dependencies for partitioned indexes are still a mess Message-ID: <20200814213534.GA8949@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20200814173008.GA21298@alvherre.pgsql> User-Agent: Mutt/1.10.1 (2018-07-13) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 2020-Aug-14, Alvaro Herrera wrote: > On 2020-Aug-12, Alvaro Herrera wrote: > > > Hmm, we do make the FK constraint depend on the ATTACH for the direct > > children; what I think we're lacking is dependencies on descendants > > twice-removed (?) or higher. This mock patch seems to fix this problem > > by adding dependencies recursively on all children of the index; I no > > longer see this problem with it. > > After going over this some more, this analysis seems correct. Here's a > better version of the patch which seems final to me. Pushed. -- Álvaro Herrera https://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services