From 6021de887558a9fb4d93278a903d30ae6112e073 Mon Sep 17 00:00:00 2001 From: AzerothCoreBot Date: Mon, 22 Apr 2019 01:09:05 +0000 Subject: [PATCH] Import pending SQL update file... Referenced commit(s): 94a1dcd5548e5454b0f6d34392e91e56b1fb2f80 --- .../2019_04_22_00.sql} | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) rename data/sql/updates/{pending_db_world/rev_1555597548140620700.sql => db_world/2019_04_22_00.sql} (91%) diff --git a/data/sql/updates/pending_db_world/rev_1555597548140620700.sql b/data/sql/updates/db_world/2019_04_22_00.sql similarity index 91% rename from data/sql/updates/pending_db_world/rev_1555597548140620700.sql rename to data/sql/updates/db_world/2019_04_22_00.sql index c8fd43629..e5836d862 100644 --- a/data/sql/updates/pending_db_world/rev_1555597548140620700.sql +++ b/data/sql/updates/db_world/2019_04_22_00.sql @@ -1,3 +1,19 @@ +-- DB update 2019_04_20_00 -> 2019_04_22_00 +DROP PROCEDURE IF EXISTS `updateDb`; +DELIMITER // +CREATE PROCEDURE updateDb () +proc:BEGIN DECLARE OK VARCHAR(100) DEFAULT 'FALSE'; +SELECT COUNT(*) INTO @COLEXISTS +FROM information_schema.COLUMNS +WHERE TABLE_SCHEMA = DATABASE() AND TABLE_NAME = 'version_db_world' AND COLUMN_NAME = '2019_04_20_00'; +IF @COLEXISTS = 0 THEN LEAVE proc; END IF; +START TRANSACTION; +ALTER TABLE version_db_world CHANGE COLUMN 2019_04_20_00 2019_04_22_00 bit; +SELECT sql_rev INTO OK FROM version_db_world WHERE sql_rev = '1555597548140620700'; IF OK <> 'FALSE' THEN LEAVE proc; END IF; +-- +-- START UPDATING QUERIES +-- + INSERT INTO `version_db_world` (`sql_rev`) VALUES ('1555597548140620700'); -- Field Marshal Afrasiabi SAI @@ -60,3 +76,12 @@ DELETE FROM `creature_text` WHERE `creatureid` IN (14392); INSERT INTO `creature_text` (`creatureid`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `comment`, `BroadcastTextId`) VALUES (14392, 0, 0, 'NEFARIAN IS SLAIN! people of Orgrimmar, bow down before the might of $N and his allies for they have laid a blow against the Black Dragonflight that is sure to stir the Aspects from their malaise! This defeat shall surely be felt by the father of the Black Flight: Deathwing reels in pain and anguish this day!', 14, 0, 100, 0, 0, 0, 'Overlord Runthak', 9867), (14392, 1, 0, 'Be lifted by $N accomplishment! Revel in his rallying cry!', 14, 0, 100, 0, 0, 0, 'Overlord Runthak', 9868); + +-- +-- END UPDATING QUERIES +-- +COMMIT; +END // +DELIMITER ; +CALL updateDb(); +DROP PROCEDURE IF EXISTS `updateDb`;