db: store file size as unsigned int

This commit is contained in:
nemunaire 2019-01-21 13:36:56 +01:00
commit 3f7e217316

View file

@ -144,7 +144,7 @@ CREATE TABLE IF NOT EXISTS exercice_files(
id_exercice INTEGER NOT NULL, id_exercice INTEGER NOT NULL,
name VARCHAR(255) NOT NULL, name VARCHAR(255) NOT NULL,
cksum BINARY(64) NOT NULL, cksum BINARY(64) NOT NULL,
size INTEGER NOT NULL, size INTEGER UNSIGNED NOT NULL,
FOREIGN KEY(id_exercice) REFERENCES exercices(id_exercice) FOREIGN KEY(id_exercice) REFERENCES exercices(id_exercice)
) DEFAULT CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci; ) DEFAULT CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci;
`); err != nil { `); err != nil {