Source

OregonCore / sql / tools / characters_pet_data_cleanup.sql

Full commit
1
2
3
4
5
6
7
-- ----------------------------------------------- --
-- Script to remove Pet Data for not existing Pets --
-- ----------------------------------------------- --

DELETE FROM pet_aura           WHERE guid NOT IN (SELECT id FROM character_pet);
DELETE FROM pet_spell          WHERE guid NOT IN (SELECT id FROM character_pet);
DELETE FROM pet_spell_cooldown WHERE guid NOT IN (SELECT id FROM character_pet);