title: Symfony2 Generate Doctrine Entities from .yml files
body: <p>So I have an existing database but I was unable to follow the steps outlined here:  <a href="http://symfony.com/doc/current/cookbook/doctrine/reverse_engineering.html" rel="nofollow">http://symfony.com/doc/current/cookbook/doctrine/reverse_engineering.html</a> because some of my tables have foreign keys for primary keys.</p>
  
  <p>My solution has been to create a copy of the database without foreign key constraints and generate the .yaml files from THAT first.</p>
  
  <p>So now I have XXX.orm.yml files in ./src/My/MainBundle/Resources/config/doctrine/metadata/orm</p>
  
  <p>Next I tried to turn these .yml files into Entity classes with annotations by using this command:
  php app/console doctrine:mapping:import MyMainBundle annotation
  However that ignores my .yml files.  It either generates the generic classes from my database without foreign keys, or it throws an error if I use it on my real database.  It never even looks at my .yml files.</p>
  
  <p>So all I want to know, is how can I transform the *.orm.yml files to Entities?</p>