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 1gkFxI-0002tK-4B for pgsql-hackers@arkaria.postgresql.org; Thu, 17 Jan 2019 22:16:08 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gkFxG-0004Vj-Sa for pgsql-hackers@arkaria.postgresql.org; Thu, 17 Jan 2019 22:16:06 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gkFxG-0004Vb-ED for pgsql-hackers@lists.postgresql.org; Thu, 17 Jan 2019 22:16:06 +0000 Received: from mail-qt1-x843.google.com ([2607:f8b0:4864:20::843]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gkFx8-0002DH-Ke for pgsql-hackers@postgresql.org; Thu, 17 Jan 2019 22:16:04 +0000 Received: by mail-qt1-x843.google.com with SMTP id p17so13183567qtl.5 for ; Thu, 17 Jan 2019 14:15:58 -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=1waCiyZHiSUN+WnNwYGCmU361sboJFH0YstOOWLYuCA=; b=XF2nz42HHpnxMCrib2xWQ6OvRLWjv7kPN2KepPosxyblvMF1xmJ8I7GVU6QSEcC/FM iSi9W1CKqZa+A//tisd6jwpZ1j9xc+vY2vF9XeMGZP5HVzcuoefsrF8iN+XOKtgzZlOn P88pJ50Ys5cEJ4AdMxPN55srgrLb3f0+wZ3liZcfJUHSIHxXP654LKEwZvlmvEGop4N7 90CX4I7TU+FtV3K+6QMampcsNfirMLP88RTdxrxTdhAVppTj8ztx7u73YGLYTuTICm9h UB29D0XXAodJiyEsaAc3M7zPIYH/X6/IWmoDIwjPx2fkaVr1W5m8ojQD6/JIpudcMN0H X+wg== 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=1waCiyZHiSUN+WnNwYGCmU361sboJFH0YstOOWLYuCA=; b=lIRResCzg34wzJ/AlhnVoaYH83U4ELj+HiKY+gDq8YrDgdL3Np4T030FhUMEuykr5j r3a+VT/PJ0R17DAEEvd7Yj6EqAoVhjSDh2j07z4id0nHMV3A3LZquEEo40/ySOI3drz6 wXhnmcqkCOr8sJyF4fSCjNywLNmVGvIFKsHeEQuC0nvAI8O/ibJL78Ga+ATIi/MUOH8T 9E5QNl58WG8Hjpla6t661f8eu/42al+MrUupNo3RZzt1U/FyaU+S6a0q1XmaE0E0QJe3 iFtkYzW/F0vI88Sq3OHUNfwiK6NTqeLo88DkQAz3g+b6/DTbbkXtG36pqtZ0ARApPNnT 3FMg== X-Gm-Message-State: AJcUukcvAKBNf8KVL46W6mWw/xXBhNd5wbLJNyjByP89AWODl5J63rg/ sbgO9X3J5FKgWg8vMMg+0QM4rj/17JY= X-Google-Smtp-Source: ALg8bN7A1S6qvGqOuCP8RBdOVo7YumKA0H8UElNH6wj5sxLmcWp0ktelFhReVDCX0b6mnXprCJifww== X-Received: by 2002:a0c:9626:: with SMTP id 35mr13085735qvx.207.1547763357842; Thu, 17 Jan 2019 14:15:57 -0800 (PST) Received: from alvin.alvh.no-ip.org ([190.121.29.3]) by smtp.gmail.com with ESMTPSA id c49sm70922461qtc.94.2019.01.17.14.15.56 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 17 Jan 2019 14:15:57 -0800 (PST) Received: by alvin.alvh.no-ip.org (Postfix, from userid 1000) id A824195C; Thu, 17 Jan 2019 19:15:54 -0300 (-03) Date: Thu, 17 Jan 2019 19:15:54 -0300 From: Alvaro Herrera To: Tom Lane Cc: Peter Geoghegan , PostgreSQL Hackers Subject: Re: Fixing findDependentObjects()'s dependency on scan order (regressions in DROP diagnostic messages) Message-ID: <201901172215.plncg34crv3b@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <15190.1547757720@sss.pgh.pa.us> User-Agent: NeoMutt/20180716-1013-2c1e88 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 2019-Jan-17, Tom Lane wrote: > DEPENDENCY_INTERNAL_AUTO, however, broke this completely, as the code > has no hesitation about making multiple entries of that kind. After > rather cursorily looking at that code, I'm leaning to the position > that DEPENDENCY_INTERNAL_AUTO is broken-by-design and needs to be > nuked from orbit. In the cases where it's being used, such as > partitioned indexes, I think that probably the right design is one > DEPENDENCY_INTERNAL dependency on the partition master index, and > then one DEPENDENCY_AUTO dependency on the matching partitioned table. As I recall, the problem with that approach is that you can't drop the partition when a partitioned index exists, because it follows the link to the parent index and tries to drop that. -- Álvaro Herrera https://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services