PluralKit/PluralKit.Core/Migrations/3.sql

15 lines
615 B
MySQL
Raw Normal View History

2020-01-23 19:19:50 +00:00
-- Same sort of psuedo-enum due to Dapper limitations. See 2.sql.
-- 1 = autoproxy off
-- 2 = front mode (first fronter)
-- 3 = latch mode (last proxyer)
-- 4 = member mode (specific member)
alter table system_guild add column autoproxy_mode int check (autoproxy_mode in (1, 2, 3, 4)) not null default 1;
-- for member mode
2020-01-23 20:20:22 +00:00
alter table system_guild add column autoproxy_member int references members (id) on delete set null;
2020-01-23 19:19:50 +00:00
-- for latch mode
-- not *really* nullable, null just means old (pre-schema-change) data.
2020-01-23 20:20:22 +00:00
alter table messages add column guild bigint default null;
update info set schema_version = 3;