How to update values in production table with foreign keys?
If  you don't change the a ID simply do a
SET FOREIGN_KEY_CHECKS=0;
TRUNCATE TABLE [database_name.]table_name;
INSERT INTO new Values
SET FOREIGN_KEY_CHECKS=1;

If you want to change the a ID
First do your updates, so that you have all changes and then disable the foreing keys