From 77de9619b51e5d4d7a4d22e77a28673bfe0ab382 Mon Sep 17 00:00:00 2001 From: Chris Miles Date: Fri, 8 Nov 2024 21:26:00 -0600 Subject: [PATCH] [Databuckets] Add database index to data_buckets (#4535) * [Databuckets] Add database index to data_buckets * Update database_update_manifest.cpp --- common/database/database_update_manifest.cpp | 12 ++++++++++++ common/version.h | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/common/database/database_update_manifest.cpp b/common/database/database_update_manifest.cpp index 63f3ba35b..e09a24664 100644 --- a/common/database/database_update_manifest.cpp +++ b/common/database/database_update_manifest.cpp @@ -5758,6 +5758,18 @@ ALTER TABLE `inventory_snapshots` ALTER TABLE `character_exp_modifiers` MODIFY COLUMN `aa_modifier` float NOT NULL DEFAULT 1.0 AFTER `instance_version`, MODIFY COLUMN `exp_modifier` float NOT NULL DEFAULT 1.0 AFTER `aa_modifier`; +)" + }, + ManifestEntry{ + .version = 9285, + .description = "2024_11_08_data_buckets_indexes.sql", + .check = "SHOW CREATE TABLE `data_buckets`", + .condition = "contains", + .match = "idx_character_expires", + .sql = R"( +CREATE INDEX idx_character_expires ON data_buckets (character_id, expires); +CREATE INDEX idx_npc_expires ON data_buckets (npc_id, expires); +CREATE INDEX idx_bot_expires ON data_buckets (bot_id, expires); )" } // -- template; copy/paste this when you need to create a new entry diff --git a/common/version.h b/common/version.h index f7a44bb87..708dbe9d2 100644 --- a/common/version.h +++ b/common/version.h @@ -42,7 +42,7 @@ * Manifest: https://github.com/EQEmu/Server/blob/master/utils/sql/db_update_manifest.txt */ -#define CURRENT_BINARY_DATABASE_VERSION 9284 +#define CURRENT_BINARY_DATABASE_VERSION 9285 #define CURRENT_BINARY_BOTS_DATABASE_VERSION 9045 #endif