title: Symfony2 Doctrine Migration --em inside the migration file
body: <p>I have 3 entity managers in my symfony project and I want to add new table to a specific entity manager.
  I know I can do this from command line by passing <code>--em=&quot;EntityManager1&quot;</code> using the command:</p>
  <pre><code>php app/console doctrine:migration:migrate --em=&quot;EntityManager1&quot;
  </code></pre>
  <p><strong>but I want to this in the code itself.</strong></p>
  <p>example:</p>
  <pre><code>public function up(Schema $schema)
  {
      $this-&gt;abortIf($this-&gt;connection-&gt;getDatabasePlatform()-&gt;getName() != &quot;mysql&quot;);�
      $this-&gt;addSql(&quot;CREATE TABLE `myTable` (
               `id` int(11) NOT NULL,
               `name` varchar(45) DEFAULT NULL,
               `email` varchar(45) DEFAULT NULL,
                PRIMARY KEY (`id`)
                ) ENGINE=InnoDB DEFAULT CHARSET=latin1�&quot;);
  }
  
  public function down(Schema $schema)
  {
      $this-&gt;abortIf($this-&gt;connection-&gt;getDatabasePlatform()-&gt;getName() != &quot;mysql&quot;); 
      $this-&gt;addSql(&quot;DROP TABLE myTable&quot;);�
  }
  </code></pre>