• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Delete char and account 30 days away! mysql command!

TKO

Syphero Owner!
Joined
Mar 10, 2008
Messages
2,252
Reaction score
27
Location
Sweden
Hey is there any mysql command to remove 30days away with account and char?
 
PHP:
DELETE FROM players WHERE lastlogin < UNIX_TIMESTAMP() - 30*24*60*60;

DELETE FROM player_items WHERE player_id NOT IN (SELECT id FROM players);
DELETE FROM player_skills WHERE player_id NOT IN (SELECT id FROM players);
DELETE FROM player_deaths WHERE player_id NOT IN (SELECT id FROM players);
DELETE FROM player_storage WHERE player_id NOT IN (SELECT id FROM players);
DELETE FROM player_viplist WHERE player_id NOT IN (SELECT id FROM players);
DELETE FROM player_depotitems WHERE player_id NOT IN (SELECT id FROM players);

DELETE FROM accounts WHERE id NOT IN (SELECT account_id FROM players);
Not tested.
 
@Cykotitan
I think your sending too unnecessary querys ;s, i think removing player will auto remove acc, and items and stuff.. ;s, no?

@TKO
I loled with you kid...
 
well i need to remove some account's and players! i have alot of players account that dosent play! and i need to remove them!
 
Back
Top