title: #1072 - Key column 'role_id' doesn't exist in table
body: <p>I am trying to add foreign key on my other table but this gave me error
  <code>#1072 - Key column 'role_id' doesn't exist in table</code></p>
  
  <p>I have created a table named <code>role</code></p>
  
  <p>then I created like this</p>
  
  <pre><code>create table role (
    role_id varchar(15)
    primary key (role_id)
  )
  </code></pre>
  
  <p>then when I try to alter table on my <code>user</code> table</p>
  
  <pre><code>alter table user
  add foreign key (role_id)
  references role(role_id)
  </code></pre>
  
  <p>and I got an error like this</p>
  
  <p><code>#1072 - Key column 'role_id' doesn't exist in table</code></p>