Bug #41693 Foreign keys: change in behaviour for insert ignore
Submitted: 23 Dec 2008 0:24 Modified: 20 Dec 2013 8:25
Reporter: Peter Gulutzan Email Updates:
Status: Won't fix Impact on me:
None 
Category:MySQL Server: General Severity:S3 (Non-critical)
Version:6.1.0-alpha-debug OS:Linux (SUSE 10.0 / 32-bit)
Assigned to: CPU Architecture:Any
Triage: Needs Triage: D3 (Medium)

[23 Dec 2008 0:24] Peter Gulutzan
Description:
I'm using mysql-6.1-fk.
I start the server with mysqld --foreign-key-all-engines=1.

I create a primary-key table and a foreign-key table.
I try to insert a non-matching row in the foreign-key table.
I get an error.
If I had started myqld without --foreign-key-all-engines=1,
there would be no error.

How to repeat:
create table t1 (s1 tinyint primary key) engine=innodb;
create table t2 (s1 tinyint, foreign key (s1) references t1 (s1)) engine=innodb;
insert into t1 values (0);
insert ignore into t2 values (1);
[23 Dec 2008 14:22] Miguel Solorzano
Thank you for the bug report. Verified as described.
[20 Dec 2013 8:25] Erlend Dahl
The 6.x project has been abandoned.