Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

SQLQuery to delete Account

Newbie Spellweaver
Joined
May 27, 2009
Messages
68
Reaction score
3
I need a SQLQuery to delete accounts fully
Delete existing characters, delete clans, etc ...
 
Pee Aitch Pee
Joined
Mar 30, 2011
Messages
630
Reaction score
422
Code:
TRUNCATE TABLE Account
TRUNCATE TABLE AccountItem
TRUNCATE TABLE Character
TRUNCATE TABLE CharacterItem
TRUNCATE TABLE Clan
TRUNCATE TABLE ClanMember
TRUNCATE TABLE Friend
TRUNCATE TABLE Login

Execute in Microsoft SQL Server.
An error will pop-up when you try to execute it but just press continue, it will work.

If anyone noticed I forgot a table, post it here. :)
 
Upvote 0
Junior Spellweaver
Joined
May 16, 2011
Messages
106
Reaction score
9
Code:
TRUNCATE TABLE Account
TRUNCATE TABLE AccountItem
TRUNCATE TABLE Character
TRUNCATE TABLE CharacterItem
TRUNCATE TABLE Clan
TRUNCATE TABLE ClanMember
TRUNCATE TABLE Friend
TRUNCATE TABLE Login

Execute in Microsoft SQL Server.
An error will pop-up when you try to execute it but just press continue, it will work.

If anyone noticed I forgot a table, post it here. :)

Well, that will delete all of the accounts, he said only 1 acc D:
 
Upvote 0
Pee Aitch Pee
Joined
Mar 30, 2011
Messages
630
Reaction score
422
According to his post he said he wanted to "delete existing accounts, characters, clans fully"
 
Upvote 0
Junior Spellweaver
Joined
May 16, 2011
Messages
106
Reaction score
9
But his title says SQLQuery to delete account, lol confusing at least you gave it some effort ;3.
 
Upvote 0
Experienced Elementalist
Joined
Oct 1, 2007
Messages
210
Reaction score
26
Dude.
DELETE FROM Account WHERE User ID='[put user id here]'
DELETE FROM Login WHERE User ID='[put user id here]'

Example:
DELETE FROM Account WHERE User ID='iceman4154'
 
Upvote 0
Newbie Spellweaver
Joined
May 27, 2009
Messages
68
Reaction score
3
Dude.
DELETE FROM Account WHERE User ID='[put user id here]'
DELETE FROM Login WHERE User ID='[put user id here]'

Example:
DELETE FROM Account WHERE User ID='iceman4154'

Yes, it deletes the accounts, but I need to delete completely and all its dependencies, Characters, Clans, Friends of the characters, etc...
 
Upvote 0
Junior Spellweaver
Joined
May 16, 2011
Messages
106
Reaction score
9
Code:
DELETE FROM Account WHERE AID='[AID]'
DELETE FROM Login WHERE AID='[AID]'
DELETE FROM Character WHERE AID='[AID]'
DELETE FROM Clan WHERE NAME='[Name]'
 
Upvote 0
Sultan of Yolo
Loyal Member
Joined
May 21, 2008
Messages
1,225
Reaction score
110
Code:
DELETE FROM Account WHERE AID='[AID]'
DELETE FROM Login WHERE AID='[AID]'
DELETE FROM Character WHERE AID='[AID]'
DELETE FROM Clan WHERE NAME='[Name]'

The Order should be:
deleting all account/character Logs.
deleting all clan members of his clan(in case hes leader).
deleting his clan.
deleting all his characters.
deleting account from Login and account table.
 
Upvote 0
Hi, I'm Omar!
Loyal Member
Joined
Jan 6, 2011
Messages
1,345
Reaction score
646
Guys what he means is emptying the whole table not deleting it.
 
Upvote 0
Back
Top