You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
14 lines
635 B
MySQL
14 lines
635 B
MySQL
|
2 months ago
|
-- Import once for existing installations before enabling promotion links.
|
||
|
|
-- New promotion links use an eight-character case-sensitive code in
|
||
|
|
-- ss_invite_code.code; the index keeps registration lookups bounded.
|
||
|
|
CREATE TABLE IF NOT EXISTS `referral_code_generation_locks` (
|
||
|
|
`id` tinyint unsigned NOT NULL,
|
||
|
|
PRIMARY KEY (`id`)
|
||
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
|
||
|
|
|
||
|
|
INSERT IGNORE INTO `referral_code_generation_locks` (`id`) VALUES (1);
|
||
|
|
|
||
|
|
ALTER TABLE `ss_invite_code`
|
||
|
|
MODIFY `code` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL,
|
||
|
|
ADD KEY IF NOT EXISTS `idx_ss_invite_code_code` (`code`);
|