thegreatt Posted November 30, 2008 Share Posted November 30, 2008 Hey, i was just wondering the easiest option to remove all users from the database and start from scratch? And ideas :? Quote Link to comment Share on other sites More sharing options...
Guest Anonymous Posted November 30, 2008 Share Posted November 30, 2008 Re: Delete Users DELETE FROM users WHERE userid != 1; DELETE FROM userstats WHERE userid != 1; Might be an idea to: TRUNCATE events; TRUNCATE mail; etc - and your log files. Quote Link to comment Share on other sites More sharing options...
shedh Posted November 30, 2008 Share Posted November 30, 2008 Re: Delete Users btw i think that you run that in mysql Quote Link to comment Share on other sites More sharing options...
daveaite Posted November 30, 2008 Share Posted November 30, 2008 Re: Delete Users I think he means and reuse the user IDs? because just deleting them seems easy enough to do :| Quote Link to comment Share on other sites More sharing options...
Bob911 Posted November 30, 2008 Share Posted November 30, 2008 Re: Delete Users What do you mean by reuse the user ID's? Quote Link to comment Share on other sites More sharing options...
daveaite Posted November 30, 2008 Share Posted November 30, 2008 Re: Delete Users Normally if you delete all users the IDs carry on as normal..... say you had 300 players and you deleted them all and there was only ID 1 left not deleted, when another user signs up they won't be ID 2 there'll be ID 301 so it skips 300 IDs still, I think he means re-starr the IDs from 2+ again. Quote Link to comment Share on other sites More sharing options...
Bob911 Posted November 30, 2008 Share Posted November 30, 2008 Re: Delete Users lol oh right I understand now. Well personally I do not know as I have not tried this. But why not just delete the ID 1 user and delete their stats and then just make that user again by the register page. Then to change to admin just change the user_level via phpmyadmin. Thats the simple thing to do... Unless anyone knows a simpler way....(HINT HINT NYNA! YOU KNOW EVERYTHING! :-D) Quote Link to comment Share on other sites More sharing options...
Bob911 Posted November 30, 2008 Share Posted November 30, 2008 Re: Delete Users Hey, i was just wondering the easiest option to remove all users from the database and start from scratch? And ideas :? He did say start from scratch so what Nyna said should do the trick. HOW CAN YOU NOT KNOW HOW TO TRUNCATE TABLES??? lol. You did say "easisest" option so I guess you were looking for something easier than that, but I assure you, that is easy! Quote Link to comment Share on other sites More sharing options...
thegreatt Posted November 30, 2008 Author Share Posted November 30, 2008 Re: Delete Users Worked like a dream. Thanks :-D Quote Link to comment Share on other sites More sharing options...
AlabamaHit Posted November 30, 2008 Share Posted November 30, 2008 Re: Delete Users ALTER TABLE `users` AUTO_INCREMENT = 1; ALTER TABLE `userstats` AUTO_INCREMENT = 1; And to any other table you delete.....This lets you "resuse" the ID lol... Quote Link to comment Share on other sites More sharing options...
Uridium Posted December 1, 2008 Share Posted December 1, 2008 Re: Delete Users Me personally iw ould have just changed the user_level to that of a bot so ya dont have to keep creating new ones lol Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.