title: Unique constraint for two columns in Mysql and indexes
body: <p>Sorry for newbie question - am I understand right that these two operators are identical in Mysql?</p>
  
  <pre><code>ALTER TABLE friends ADD CONSTRAINT UNIQUE (`user_id`, `friend_id`);
  </code></pre>
  
  <p>and</p>
  
  <pre><code>CREATE UNIQUE INDEX friends_user_friend ON friends (user_id, friend_id);
  </code></pre>