13 messages in com.mysql.lists.mysqlRe: mySQL and innoDB
FromSent OnAttachments
Rance Hall09 Apr 2002 09:25 
Alain Del Giust09 Apr 2002 09:27 
Rance Hall09 Apr 2002 09:41 
Alain Del Giust09 Apr 2002 09:44 
tara...@wige-data.de09 Apr 2002 09:50 
Christopher Thompson09 Apr 2002 10:04 
Alain Del Giust09 Apr 2002 10:06 
Rance Hall09 Apr 2002 10:21 
Christopher Thompson09 Apr 2002 10:43 
Alain Del Giust09 Apr 2002 10:47 
Rance Hall09 Apr 2002 11:20 
Heikki Tuuri09 Apr 2002 12:21 
Benjamin Pflugmann09 Apr 2002 17:01 
Subject:Re: mySQL and innoDB
From:Benjamin Pflugmann (benj@pflugmann.de)
Date:04/09/2002 05:01:17 PM
List:com.mysql.lists.mysql

Hi.

Is there a chance that you make this behaviour dependend on the --ansi switch? I never used foreign keys until now, but from the theory I would expect that a missing "not null" declaration on a FK declaration should either be implicitly assumed or result in an error - at least on insert.

I meanwhile see why others databases have softened the foreign key constraint, but I would call accepting NULLs unexpected behaviour from what I have learned about FK.

Bye,

Benjamin.

On Tue, Apr 09, 2002 at 10:22:21PM +0300, Heik@innodb.com wrote:

Hi!

From the changelog of 3.23.50:

* We suppress the FOREIGN KEY check if any of the column values in the foreign key or referenced key to be checked is the SQL NULL. This is compatible with Oracle, for example.

It is conceptually a bit strange that we first declare a FOREIGN KEY constraint, but then let a user to slip it through using a NULL value. But, since we may declare a column as NOT NULL, we can still force full referential integrity in 3.23.50.

[...]