PDA

View Full Version : mysql error 1217



boogyman
11-07-2007, 03:33 PM
I have never seen this error before and I was wondering if anyone knows of the fix?



ERROR 1217 (23000) at line 243: Cannot delete or update a parent row: a foreign key constraint fails



ln243: DROP TABLE IF EXISTS 'downloads';


I checked the mysql development site and haven't been too successful in finding a solution... thought maybe someone here might know.

Twey
11-07-2007, 04:39 PM
You've got a foreign key elsewhere that points to a row in `downloads`.

boogyman
11-07-2007, 06:14 PM
yah I got that part.
Is there some type of option to enable to ignore this ?

Twey
11-07-2007, 07:43 PM
No, you need to remove the reference.

boogyman
11-08-2007, 02:23 PM
its actually coming from a mysql dump... so everytime I import the dump I would need to manually remove and read the reference?

that doesnt sound like a very efficient use of a mirrored server :)) which is what I was attempting to create in the first place.

Twey
11-08-2007, 05:19 PM
In that case you need to modify the dump so that it executes in the right order and doesn't break anything.