title: MariaDB won't create table with large VARCHAR as PRIMARY KEY
body: <p>I tried to create a table in MariaDB, I wanted it to be VARCHAR(767) and PRIMARY KEY. I used this command but this is not what I want to.</p>
  
  <pre><code>CREATE TABLE main(username VARCHAR(767)  NOT NULL);
  </code></pre>
  
  <p>This command is executed, but if I add PRIMARY KEY the error will be appeared.</p>
  
  <pre><code>CREATE TABLE main(username VARCHAR(767) NOT NULL PRIMARY KEY);
  ERROR 1071 (42000): Specified key was too long; max key length is 767 bytes
  </code></pre>