title: Add foreign key in Yii migrations
body: <p>I try to add foreign key to table, but when I run migration I getting this error:</p>
  
  <pre><code> General error: 1005 Can't create table 'chooseone.#sql-49a_49'
  </code></pre>
  
  <p>Its strange because <code>chooseone</code> is the name of my database. Here is how I try to add FK:</p>
  
  <pre><code>$this-&gt;addForeignKey('FK_user_profile', 'tbl_profile', 'user_id', 'tbl_user', 'id', 'CASCADE', 'CASCADE');
  </code></pre>
  
  <p>So what I am doing wrong?</p>