correct charset for contact column

Fixes #819.
This commit is contained in:
Jeff Hodges 2015-10-05 14:59:57 -07:00
parent b6572263c3
commit 7ad8874f06
1 changed files with 12 additions and 0 deletions

View File

@ -0,0 +1,12 @@
-- +goose Up
-- SQL in section 'Up' is executed when this migration is applied
-- Adjust utf8mb4 is the real 4-byte UTF-8. But to fit the contact column in an
-- index entirely, we need to adjust 255 down to 191.
ALTER TABLE `registrations` MODIFY COLUMN contact varchar(191) CHARACTER SET utf8mb4 NOT NULL;
-- +goose Down
-- SQL section 'Down' is executed when this migration is rolled back
ALTER TABLE `registrations` MODIFY COLUMN contact varchar(255) CHARACTER SET utf8 NOT NULL;