From 959947155fc1b080fb8da866b5d1987d7ee93c5a Mon Sep 17 00:00:00 2001 From: Orgad Shaneh Date: Tue, 3 Oct 2017 15:59:45 +0300 Subject: [PATCH] Doc: Set default character set for MySQL The system's default (at least for MariaDB) is utf8mb4, and when it is used - 255 chars for primary key is too long (error: Specified key was too long; max key length is 767 bytes) Change-Id: I1120f07079e6c9aa9a570d3da64aecd33216650a --- Documentation/database-setup.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/database-setup.txt b/Documentation/database-setup.txt index db4069b4fb..2dbec2d65f 100644 --- a/Documentation/database-setup.txt +++ b/Documentation/database-setup.txt @@ -68,7 +68,7 @@ rights on it: mysql CREATE USER 'gerrit2'@'localhost' IDENTIFIED BY 'secret'; - CREATE DATABASE reviewdb; + CREATE DATABASE reviewdb DEFAULT CHARACTER SET 'utf8'; GRANT ALL ON reviewdb.* TO 'gerrit2'@'localhost'; FLUSH PRIVILEGES; ----