Guys,

I'm attempting to reapply a number of bin-log files in a effort to restore all changes that was made to a database. I'm performing the following command, but continue to get a foreign key constraint error message when doing so. Has anyone ever ran into this issue, and if so, what is a potential workaround? A possible solution is to set foreign key check to "0", but this from what I understand is done at the session level and cannot be applied in my situation. Any help would be greatly appreciated.

 mysqlbinlog oca-bin.000554 | mysql -h -u -p oca
ERROR 1452 (23000) at line 125: Cannot add or update a child row: a foreign key constraint fails (`oca/invbodytax`, CONSTRAINT `invbodytax_ibfk_1` FOREIGN KEY (`inbtStore`, `inbtActNumber`, `inbtRef`, `inbtItem`) REFERENCES `invbody` (`inbStore`, `inbActNumber`, `inbRef`, `inbItem`) ON DEL)

Thanks in advance,


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Clyde Lewis
Database Administrator


Reply via email to