17 lines
550 B
MySQL
17 lines
550 B
MySQL
|
ALTER TABLE `vn`.`chat` ADD statusNew enum('pending','sent','error','sending') DEFAULT 'pending' NOT NULL;
|
||
|
|
||
|
UPDATE `vn`.`chat`
|
||
|
SET statusNew = 'pending'
|
||
|
WHERE status = 0;
|
||
|
|
||
|
UPDATE `vn`.`chat`
|
||
|
SET statusNew = 'sent'
|
||
|
WHERE status = 1;
|
||
|
|
||
|
UPDATE `vn`.`chat`
|
||
|
SET statusNew = 'error'
|
||
|
WHERE status = 2;
|
||
|
|
||
|
ALTER TABLE `vn`.`chat` CHANGE status status__ tinyint(1) DEFAULT NULL NULL;
|
||
|
ALTER TABLE `vn`.`chat` CHANGE statusNew status enum('pending','sent','error','sending') CHARACTER SET utf8mb3 COLLATE utf8mb3_unicode_ci DEFAULT 'pending' NOT NULL;
|