From efbbd53955ce655c4ffc701b9e80e3dc96f00230 Mon Sep 17 00:00:00 2001 From: Mikhail Solovev Date: Thu, 30 May 2024 05:40:27 +0300 Subject: [PATCH] Update 0.82.0-0.83.0.sql Forgot to update schema to work with Boosts properly --- utils/db-schema-update/0.82.0-0.83.0.sql | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/utils/db-schema-update/0.82.0-0.83.0.sql b/utils/db-schema-update/0.82.0-0.83.0.sql index 537307c7..6b9a7eac 100644 --- a/utils/db-schema-update/0.82.0-0.83.0.sql +++ b/utils/db-schema-update/0.82.0-0.83.0.sql @@ -69,3 +69,9 @@ ALTER TABLE `message` ALTER TABLE `telegram_update` ADD COLUMN `message_reaction_id` bigint UNSIGNED DEFAULT NULL COMMENT 'A reaction to a message was changed by a user' AFTER `edited_channel_post_id`, ADD COLUMN `message_reaction_count_id` bigint UNSIGNED DEFAULT NULL COMMENT 'Reactions to a message with anonymous reactions were changed' AFTER `message_reaction_id`; + +ALTER TABLE `telegram_update` ADD COLUMN `chat_boost_updated_id` BIGINT UNSIGNED NULL COMMENT 'A boost update the chat has been sent'; +ALTER TABLE `telegram_update` ADD FOREIGN KEY (`chat_boost_updated_id`) REFERENCES `chat_boost_updated` (`id`); + +ALTER TABLE `telegram_update` ADD COLUMN `chat_boost_removed_id` BIGINT UNSIGNED NULL COMMENT 'A boost remove from the chat has been sent'; +ALTER TABLE `telegram_update` ADD FOREIGN KEY (`chat_boost_removed_id`) REFERENCES `chat_boost_removed` (`id`);