From: | "Christopher Kings-Lynne" <chriskl(at)familyhealth(dot)com(dot)au> |
---|---|
To: | "Hackers" <pgsql-hackers(at)postgresql(dot)org>, "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Subject: | Bug with CREATE CONSRAINT TRIGGER and attisdropped |
Date: | 2002-08-15 05:55:20 |
Message-ID: | GNELIHDDFBOCMGBFGEFOOELHCDAA.chriskl@familyhealth.com.au |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
CREATE CONSTRAINT TRIGGER doesn't respect attisdropped. Unfortunately I
really don't have the time to submit a patch at the moment - sorry :(
ctest=# create table master (x int unique, y int4 unique);
NOTICE: CREATE TABLE / UNIQUE will create implicit index 'master_x_key' for
table 'master'
NOTICE: CREATE TABLE / UNIQUE will create implicit index 'master_y_key' for
table 'master'
CREATE TABLE
test=# create table slave (a int);
CREATE TABLE
test=# alter table master drop x;
ALTER TABLE
test=# create constraint trigger "$1" after insert or update on "slave" from
master not deferrable initially immediate for each row execute procedure
"RI_FKey_check_ins" ('$1', 'slave', 'master', 'UNSPECIFIED', 'a', 'x');
CREATE TRIGGER
test=# insert into master values (1);
INSERT 16982 1
test=# insert into slave values (2);
ERROR: constraint $1: table master does not have an attribute x
Chris
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2002-08-15 06:03:18 | Re: Bug with CREATE CONSRAINT TRIGGER and attisdropped |
Previous Message | Tom Lane | 2002-08-15 05:54:23 | Re: Open 7.3 issues |