La mise à jour du schéma de doctrine Symfony2 échoue

J'ai créé la base de données sur ma machine locale. Après le déplacement de mon projet de serveur j'ai importé une sauvegarde locale (parce que j'ai eu quelques données importantes).

Maintenant,quand je suis en train de mettre à jour le schéma sur mon serveur, il donne à mon cette sortie:

php app/console doctrine:schema:update --force
Updating database schema...





  [Doctrine\DBAL\Exception\ForeignKeyConstraintViolationException]                                                                                                             
  An exception occurred while executing 'ALTER TABLE golf_course ADD CONSTRAINT FK_EC96E162F1503E2B FOREIGN KEY (golf_id) REFERENCES golf (id)':                               
  SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails (`GolfFairway`.`#sql-3fae_7ccf1`, CONSTRAINT `FK_EC9  
  6E162F1503E2B` FOREIGN KEY (`golf_id`) REFERENCES `golf` (`id`))                                                                                                             






  [Doctrine\DBAL\Driver\PDOException]                                                                                                                                          
  SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails (`GolfFairway`.`#sql-3fae_7ccf1`, CONSTRAINT `FK_EC9  
  6E162F1503E2B` FOREIGN KEY (`golf_id`) REFERENCES `golf` (`id`))                                                                                                             






  [PDOException]                                                                                                                                                               
  SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails (`GolfFairway`.`#sql-3fae_7ccf1`, CONSTRAINT `FK_EC9  
  6E162F1503E2B` FOREIGN KEY (`golf_id`) REFERENCES `golf` (`id`))                                                                                                             

Pourquoi cela se produit ? Est-il une solution ?

source d'informationauteur Maxian Nicu