Last active
August 10, 2019 08:33
-
-
Save jackpoz/539889d2fd1101e607218370e1ea647f to your computer and use it in GitHub Desktop.
clean bots
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
DELETE FROM auth.account WHERE username LIKE 'bot%' AND username != 'botfarm'; | |
DELETE t FROM auth.realmcharacters AS t LEFT JOIN auth.account AS a ON t.acctid = a.id WHERE a.id IS NULL; | |
DELETE c FROM characters.characters AS c LEFT JOIN auth.account AS a ON c.account = a.id WHERE a.id IS NULL; | |
DELETE t FROM characters.character_skills AS t LEFT JOIN characters.characters AS c ON t.guid = c.guid WHERE c.guid IS NULL; | |
DELETE t FROM characters.character_reputation AS t LEFT JOIN characters.characters AS c ON t.guid = c.guid WHERE c.guid IS NULL; | |
DELETE t FROM characters.character_inventory AS t LEFT JOIN characters.characters AS c ON t.guid = c.guid WHERE c.guid IS NULL; | |
DELETE t FROM characters.character_homebind AS t LEFT JOIN characters.characters AS c ON t.guid = c.guid WHERE c.guid IS NULL; | |
DELETE t FROM characters.character_glyphs AS t LEFT JOIN characters.characters AS c ON t.guid = c.guid WHERE c.guid IS NULL; | |
DELETE t FROM characters.character_battleground_data AS t LEFT JOIN characters.characters AS c ON t.guid = c.guid WHERE c.guid IS NULL; | |
DELETE t FROM characters.character_aura AS t LEFT JOIN characters.characters AS c ON t.guid = c.guid WHERE c.guid IS NULL; | |
DELETE t FROM characters.character_action AS t LEFT JOIN characters.characters AS c ON t.guid = c.guid WHERE c.guid IS NULL; | |
DELETE t FROM characters.character_achievement_progress AS t LEFT JOIN characters.characters AS c ON t.guid = c.guid WHERE c.guid IS NULL; | |
DELETE t FROM characters.character_achievement AS t LEFT JOIN characters.characters AS c ON t.guid = c.guid WHERE c.guid IS NULL; | |
DELETE t FROM characters.character_account_data AS t LEFT JOIN characters.characters AS c ON t.guid = c.guid WHERE c.guid IS NULL; | |
DELETE t FROM characters.item_instance AS t LEFT JOIN characters.characters AS c ON t.owner_guid = c.guid WHERE c.guid IS NULL; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment