BUG #9606: pg_class relhaspkey column not updated on removal of primary key

From: jeff(at)pgexperts(dot)com
To: pgsql-bugs(at)postgresql(dot)org
Subject: BUG #9606: pg_class relhaspkey column not updated on removal of primary key
Date: 2014-03-17 18:52:55
Message-ID: 20140317185255.20724.49675@wrigleys.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

The following bug has been logged on the website:

Bug reference: 9606
Logged by: Jeff Frost
Email address: jeff(at)pgexperts(dot)com
PostgreSQL version: 9.2.7
Operating system: Linux
Description:

pkey_test=# show server_version;
server_version
----------------
9.2.7
(1 row)

pkey_test=# create table foo ( bar serial primary key);
NOTICE: CREATE TABLE will create implicit sequence "foo_bar_seq" for serial
column "foo.bar"
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index "foo_pkey"
for table "foo"
CREATE TABLE

pkey_test=# select relname, relhaspkey FROM pg_class where relname = 'foo';
relname | relhaspkey
---------+------------
foo | t
(1 row)

pkey_test=# alter table foo drop constraint foo_pkey;
ALTER TABLE

pkey_test=# select relname, relhaspkey FROM pg_class where relname = 'foo';
relname | relhaspkey
---------+------------
foo | t
(1 row)

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2014-03-17 18:59:30 Re: BUG #9606: pg_class relhaspkey column not updated on removal of primary key
Previous Message Jeff Frost 2014-03-17 18:48:59 Re: BUG #8660: RPM installation of 9.2.6 have dependency problem