Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WPiia-0002ZP-E0 for pgsql-bugs@arkaria.postgresql.org; Tue, 18 Mar 2014 01:21:24 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1WPiiZ-0000NS-Uw for pgsql-bugs@arkaria.postgresql.org; Tue, 18 Mar 2014 01:21:23 +0000 Received: from makus.postgresql.org ([2001:4800:7903:4::125]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WPiiZ-0000N4-7K for pgsql-bugs@postgresql.org; Tue, 18 Mar 2014 01:21:23 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WPiiW-0005Ot-LI for pgsql-bugs@postgresql.org; Tue, 18 Mar 2014 01:21:22 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id s2I1LJhc014342; Mon, 17 Mar 2014 21:21:19 -0400 From: Tom Lane To: Jeff Frost cc: pgsql-bugs@postgresql.org Subject: Re: BUG #9606: pg_class relhaspkey column not updated on removal of primary key In-reply-to: References: <20140317185255.20724.49675@wrigleys.postgresql.org> <25726.1395082770@sss.pgh.pa.us> <7FBC4B95-6AF6-4CFC-A4E2-DE7D9C30AB4B@pgexperts.com> Comments: In-reply-to Jeff Frost message dated "Mon, 17 Mar 2014 17:48:36 -0700" Date: Mon, 17 Mar 2014 21:21:19 -0400 Message-ID: <14341.1395105679@sss.pgh.pa.us> X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org Jeff Frost writes: > Interestingly, on 9.1.11, I have a table where the pkey was added after the fact, then dropped, but it still shows as relhaspkey even though I manually vacuumed it: IIRC, VACUUM only clears relhaspkey if there are *no* indexes left --- it doesn't bother to check whether there's one calling itself indisprimary. We could possibly change that but it's not clear that it's worth any effort, given that the column would still have to be defined the same way. regards, tom lane -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs