mirror of
https://github.com/araxiaonline/TrinityCore.git
synced 2026-06-17 13:39:46 -04:00
b150172521
- Separate rewarded quests from active quests, and store them in a new table to reduce database size - Drop the no longer needed `rewarded` column from character_queststatus for smaller table size - Prevent filling the database with dropped quests - Delete useless records - Implement queststatus save "queues" instead of states - Minor optimizations WARNING: Backup your database! --HG-- branch : trunk
14 lines
631 B
SQL
14 lines
631 B
SQL
DELETE FROM character_queststatus WHERE `status` = 0;
|
|
|
|
DROP TABLE IF EXISTS `character_queststatus_rewarded`;
|
|
CREATE TABLE `character_queststatus_rewarded` (
|
|
`guid` int(10) unsigned NOT NULL default '0' COMMENT 'Global Unique Identifier',
|
|
`quest` int(10) unsigned NOT NULL default '0' COMMENT 'Quest Identifier',
|
|
PRIMARY KEY (`guid`,`quest`)
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Player System';
|
|
|
|
INSERT INTO character_queststatus_rewarded SELECT guid, quest FROM character_queststatus WHERE rewarded = 1;
|
|
DELETE FROM character_queststatus WHERE rewarded = 1;
|
|
|
|
ALTER TABLE character_queststatus DROP COLUMN rewarded;
|