Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 114735 - mysql-5.0.16-r3 innodb tables do not check foreign key constraints
Summary: mysql-5.0.16-r3 innodb tables do not check foreign key constraints
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo Linux MySQL bugs team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-12-07 04:35 UTC by Gerben Gieling
Modified: 2005-12-07 08:10 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gerben Gieling 2005-12-07 04:35:29 UTC
I exported my tables using mysqldump out of mysql 4.0 emerged mysql-5.0.16-r3
and loaded the mysqldump file back into the new mysql. Even though the table
definitions were in wrong order, data was loaded without error message.
Also when I deleted a row in table a, related rows in tables b and c having
foreign key constraints to table a (on delete cascade) were not deleted.
The same for update constraints

Reproducible: Always
Steps to Reproduce:
1.emerge mysql-5.0.16-r3
2.restore old (innodb) databases with foreign key constraints
3.remove or update a row in a cited table

Actual Results:  
related rows in citing tables not removed/updated

Expected Results:  
related rows in citing table should be removed/updated

The ebuild contains the option --skip-innodb on line 730.
Why is this?
I assumed that the removal of the innodb use variable would enable innodb as
standard instead of removing it
Comment 1 Francesco R. (RETIRED) gentoo-dev 2005-12-07 08:10:22 UTC
(In reply to comment #0)
> I exported my tables using mysqldump out of mysql 4.0 emerged mysql-5.0.16-r3
> and loaded the mysqldump file back into the new mysql. Even though the table
> definitions were in wrong order, data was loaded without error message.
> Also when I deleted a row in table a, related rows in tables b and c having
> foreign key constraints to table a (on delete cascade) were not deleted.
> The same for update constraints

too huge problem for my little energies, some hints:
read http://dev.mysql.com/doc/refman/5.0/en/upgrade.html
one of suggestion is:
----------
As a general rule, we recommend that when upgrading from one release series to
another, you should go to the next series rather than skipping a series. For
example, if you currently are running MySQL 3.23 and wish to upgrade to a newer
series, upgrade to MySQL 4.0 rather than to 4.1 or 5.0.
----------

[...]

> The ebuild contains the option --skip-innodb on line 730.
> Why is this?
> I assumed that the removal of the innodb use variable would enable innodb as
> standard instead of removing it

this is used to initialize a database in the function pkg_config() , it's called
only during a "emerge --config mysql"

innodb actually is always _compiled_ in so to disable a "skip-innodb" in the
my.cnf file is needed. Further note, this may change in a not so far future and
go back to an optional innodb use flag.

Regards,
Francesco R.