fix(Core/Query): Escape MySQL 8.0 Keyword (#3052)
This commit is contained in:
parent
9745fc52d8
commit
dca4fd3d7c
1 changed files with 1 additions and 1 deletions
|
|
@ -94,7 +94,7 @@ void GroupMgr::LoadGroups()
|
|||
CharacterDatabase.DirectExecute("DELETE FROM `groups` WHERE leaderGuid NOT IN (SELECT guid FROM characters)");
|
||||
// Delete all groups with less than 2 members (or less than 1 for lfg groups)
|
||||
// TODO: This query is not allowed in MySQL 8.0
|
||||
CharacterDatabase.DirectExecute("DELETE groups FROM `groups` LEFT JOIN ((SELECT guid, count(*) as cnt FROM group_member GROUP BY guid) t) ON groups.guid = t.guid WHERE t.guid IS NULL OR (t.cnt<=1 AND groups.groupType <> 12)");
|
||||
CharacterDatabase.DirectExecute("DELETE `groups` FROM `groups` LEFT JOIN ((SELECT guid, count(*) as cnt FROM group_member GROUP BY guid) t) ON groups.guid = t.guid WHERE t.guid IS NULL OR (t.cnt<=1 AND groups.groupType <> 12)");
|
||||
// Delete invalid lfg_data
|
||||
// TODO: This query is not allowed in MySQL 8.0
|
||||
CharacterDatabase.DirectExecute("DELETE lfg_data FROM lfg_data LEFT JOIN `groups` ON lfg_data.guid = groups.guid WHERE groups.guid IS NULL OR groups.groupType <> 12");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue