Apply a quick fix for foreign key constraint