canadian_angel Posted July 15, 2010 Share Posted July 15, 2010 I added a user to my database ijdb for a project i am doing and have tried repeatedly to delete them with no luck. The user is jess; mysql>GRANT SELECT ON ijdb.* ->TO jess@"%.host.net" ->IDENTIFIED BY "jessrules"; mysql>GRANT UPDATE (name, email) ON ijdb.author ->TO jess@"%.host.net"; I have tryed DELETE, and DROP USER.............etc. no luck. Can someone please help! Quote Link to comment https://forums.phpfreaks.com/topic/207876-delete-user-from-database/ Share on other sites More sharing options...
premiso Posted July 15, 2010 Share Posted July 15, 2010 Try: DELETE FROM mysql.user WHERE User = 'jess' You can limit that further by adding the host or database, do a DESC mysql.user For other fields you could query by. Quote Link to comment https://forums.phpfreaks.com/topic/207876-delete-user-from-database/#findComment-1086706 Share on other sites More sharing options...
fenway Posted July 15, 2010 Share Posted July 15, 2010 Yes, but you should probably use the administrative commands to do this, since playing with the mysql internal database it just a bad idea. Quote Link to comment https://forums.phpfreaks.com/topic/207876-delete-user-from-database/#findComment-1086777 Share on other sites More sharing options...
premiso Posted July 16, 2010 Share Posted July 16, 2010 since playing with the mysql internal database it just a bad idea. It is a bad idea, I would agree. But I have had issues with Drop USER messing up and the only way to remediate was to manually delete it. Since he hinted that he tried the DROP USER command to no avail, I figured that he needed another means of doing it. Quote Link to comment https://forums.phpfreaks.com/topic/207876-delete-user-from-database/#findComment-1086803 Share on other sites More sharing options...
Pikachu2000 Posted July 16, 2010 Share Posted July 16, 2010 If you are using MySQL version 4.1.1 to 5.0.2, see the MySQL manual for DROP USER syntax. You have to revoke all privileges before performing the DROP. Quote Link to comment https://forums.phpfreaks.com/topic/207876-delete-user-from-database/#findComment-1086876 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.