carl101 Posted December 20, 2014 Report Share Posted December 20, 2014 Hi guys, iv looked all over and cant seem to find a sql to delete player login logs as i have over 19k! and need some serious cleanup. any helps appreciated. thanks Link to comment Share on other sites More sharing options...
0 Defent Posted December 20, 2014 Report Share Posted December 20, 2014 Create an event that runs like every day or every 3rd hour or whatever and then just add this code to it: BEGIN DELETE FROM `player_login` WHERE playerUID > 1; END carl101 1 Link to comment Share on other sites More sharing options...
0 carl101 Posted December 20, 2014 Author Report Share Posted December 20, 2014 cheers for that buddy Link to comment Share on other sites More sharing options...
0 jahangir13 Posted December 21, 2014 Report Share Posted December 21, 2014 If you want to keep data for a few days to see who logged in/out when, you can use the datastamp column: DELETE FROM `Player_LOGIN` WHERE `Datestamp` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 2 DAY); So it keeps the rows not older than 2 days in this example. carl101 1 Link to comment Share on other sites More sharing options...
0 carl101 Posted December 21, 2014 Author Report Share Posted December 21, 2014 sweet, thanks for that jahangir. Link to comment Share on other sites More sharing options...
Question
carl101
Hi guys, iv looked all over and cant seem to find a sql to delete player login logs as i have over 19k! and need some serious cleanup.
any helps appreciated.
thanks
Link to comment
Share on other sites
4 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now