Voglio iniziare a scrivere query in MySQL.
show grants Spettacoli:
+--------------------------------------+
| Grants for @localhost |
+--------------------------------------+
| GRANT USAGE ON *.* TO ''@'localhost' |
+--------------------------------------+
Non ho un ID utente ma quando voglio fare un utente non ho privilegi, inoltre non so come fare privilegi quando nemmeno io ho un utente!
mysql> CREATE USER 'parsa'@'localhost' IDENTIFIED BY 'parsa';
ERROR 1227 (42000): Access denied; you need (at least one of) the CREATE USER pr
ivilege(s) for this operation
Ho provato ad accedere come root:
mysql> mysql -u root -p;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that
corresponds to your MySQL server version for the right syntax to use near 'mysql
-u root -p' at line 1
mysql> mysql -u root -p root;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that
corresponds to your MySQL server version for the right syntax to use near 'mysql
-u root -p root' at line 1
mysql -u root -p. Quindi avrai le autorizzazioni complete sul server di database e puoi creare altri utenti.


rootavrebbe dovuto essere creato quando hai installato MySQL.