@@ -1424,10 +1424,10 @@ insert into rule_and_refint_t3 values (1, 12, 11, 'row3');
14241424insert into rule_and_refint_t3 values (1, 12, 12, 'row4');
14251425insert into rule_and_refint_t3 values (1, 11, 13, 'row5');
14261426ERROR: insert or update on table "rule_and_refint_t3" violates foreign key constraint "rule_and_refint_t3_id3a_fkey1"
1427- DETAIL: Key (id3a,id3c)=(1,13) is not present in table "rule_and_refint_t2".
1427+ DETAIL: Key (id3a, id3c)=(1, 13) is not present in table "rule_and_refint_t2".
14281428insert into rule_and_refint_t3 values (1, 13, 11, 'row6');
14291429ERROR: insert or update on table "rule_and_refint_t3" violates foreign key constraint "rule_and_refint_t3_id3a_fkey"
1430- DETAIL: Key (id3a,id3b)=(1,13) is not present in table "rule_and_refint_t1".
1430+ DETAIL: Key (id3a, id3b)=(1, 13) is not present in table "rule_and_refint_t1".
14311431create rule rule_and_refint_t3_ins as on insert to rule_and_refint_t3
14321432 where (exists (select 1 from rule_and_refint_t3
14331433 where (((rule_and_refint_t3.id3a = new.id3a)
@@ -1439,10 +1439,18 @@ create rule rule_and_refint_t3_ins as on insert to rule_and_refint_t3
14391439 and (rule_and_refint_t3.id3c = new.id3c));
14401440insert into rule_and_refint_t3 values (1, 11, 13, 'row7');
14411441ERROR: insert or update on table "rule_and_refint_t3" violates foreign key constraint "rule_and_refint_t3_id3a_fkey1"
1442- DETAIL: Key (id3a,id3c)=(1,13) is not present in table "rule_and_refint_t2".
1442+ DETAIL: Key (id3a, id3c)=(1, 13) is not present in table "rule_and_refint_t2".
14431443insert into rule_and_refint_t3 values (1, 13, 11, 'row8');
14441444ERROR: insert or update on table "rule_and_refint_t3" violates foreign key constraint "rule_and_refint_t3_id3a_fkey"
1445- DETAIL: Key (id3a,id3b)=(1,13) is not present in table "rule_and_refint_t1".
1445+ DETAIL: Key (id3a, id3b)=(1, 13) is not present in table "rule_and_refint_t1".
1446+ --
1447+ -- disallow dropping a view's rule (bug #5072)
1448+ --
1449+ create view fooview as select 'foo'::text;
1450+ drop rule "_RETURN" on fooview;
1451+ ERROR: cannot drop rule _RETURN on view fooview because view fooview requires it
1452+ HINT: You can drop view fooview instead.
1453+ drop view fooview;
14461454--
14471455-- check for planner problems with complex inherited UPDATES
14481456--
0 commit comments