From: | "Christopher Kings-Lynne" <chriskl(at)familyhealth(dot)com(dot)au> |
---|---|
To: | "Pgsql-Hackers" <pgsql-hackers(at)postgresql(dot)org> |
Subject: | CHECK constraint names |
Date: | 2000-12-20 04:18:11 |
Message-ID: | NEBBIOAJBMEENKACLNPCIELHCCAA.chriskl@familyhealth.com.au |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
Is it correct behaviour that unnamed table-level check constraints get the
names '$1', '$2', '$3', etc. in Postgres 7.0.3???
Eg, using table constraints:
----------------------------
test=# create table test (temp char(1) NOT NULL, CHECK (temp IN ('M',
'F')));
CREATE
test=# select rcname from pg_relcheck;
rcname
$1
(1 row)
And, even worse - I think this has got to be a bug:
---------------------------------------------------
test=# create table test (temp char(1) NOT NULL, CHECK (temp IN ('M',
'F')));
CREATE
test=# create table test2 (temp char(1) NOT NULL, CHECK (temp IN ('M',
'F')));
CREATE
test=# select rcname from pg_relcheck;
rcname
--------
$1
$1
(2 rows)
Two constraints with the same name!!!!
And if you use column constraints:
----------------------------------
test=# create table test (temp char(1) NOT NULL CHECK (temp IN ('M', 'F')));
CREATE
test=# select rcname from pg_relcheck;
rcname
-----------
test_temp
(1 row)
--
Christopher Kings-Lynne
Family Health Network (ACN 089 639 243)
From | Date | Subject | |
---|---|---|---|
Next Message | bpalmer | 2000-12-20 05:46:33 | 7.1 snapshot on i386 BSD MAJOR failure |
Previous Message | Ryan Kirkpatrick | 2000-12-20 04:08:00 | PostgreSQL pre-7.1 Linux/Alpha Status... |