Mysql: Difference between revisions
From AWVVO
Jump to navigationJump to search
Line 6: | Line 6: | ||
SHOW GRANTS FOR 'newuser'@'localhost'; | SHOW GRANTS FOR 'newuser'@'localhost'; | ||
</syntaxhighlight> | </syntaxhighlight> | ||
{| class="wikitable" | |||
|+ | |||
!show version | |||
!mysql -V | |||
! | |||
! | |||
|- | |||
| | |||
| | |||
| | |||
| | |||
|- | |||
| | |||
| | |||
| | |||
| | |||
|- | |||
| | |||
| | |||
| | |||
| | |||
|} |
Revision as of 07:24, 16 February 2025
Create user
CREATE USER 'username'@'host' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON database_name.* TO 'username'@'host';
FLUSH PRIVILEGES;
SHOW GRANTS FOR 'newuser'@'localhost';
show version | mysql -V | ||
---|---|---|---|