Fulltext results:
- MySQL: Create User
- QL: Create User ====== ==== Create User ==== <code sql> CREATE USER '{user}'@'%' IDENTIFIED BY '{passwd}'; </code> ==== Create User and Database ==== * Usually, ''{user}'' == ''{db}'' <code sql> CREATE USER '{user}'@'%' IDENTIFIED BY '{pas... LL PRIVILEGES ON `{db}` . * TO '{user}'@'%'; </code> Simpler Alternative: <code sql> CREATE DATABAS
- MySQL: Remove User
- QL: Remove User ====== ==== Remove User ==== <code sql> DROP USER '{user}'@'%'; </code> ==== Remove User and Database ==== * Usually, {user} == {db} <code sql> DROP USER '{user}'@'%'; DROP DATABASE '{db}'; </code> {{tag>admin database mysql sql}}
- MySQL: Change Password
- Replace ''{user}'' with the name of the user. <code sql> GRANT USAGE ON *.* TO '{user}'@'%' IDENTIFIED BY '{passwd}'; FLUSH PRIVILEGES; </code> Or you can alternatively use the following: <code sql> UPDATE mysql.user SET Password=PASSWORD('{passwd}') WHERE User='{user}'; FLUSH PRIVILEGES; </code> {{tag>admin database mysql password sql}}