Complete the code to connect to a MySQL server using the CLI.
mysql -u [1] -pUse the -u option to specify the username, commonly root for admin access.
Complete the command to show all databases in MySQL CLI.
[1];SHOW TABLES; which only shows tables in the current database.LIST DATABASES; which is not valid MySQL syntax.The command SHOW DATABASES; lists all databases on the MySQL server.
Fix the error in the command to select a database named 'shop'.
USE [1];The database name is case-sensitive in some systems. Use the exact name shop.
Fill both blanks to create a new user 'alice' with password 'mypassword' in MySQL CLI.
CREATE USER '[1]'@'localhost' IDENTIFIED BY '[2]';
Use CREATE USER 'alice'@'localhost' IDENTIFIED BY 'mypassword'; to create the user with the password.
Fill all three blanks to grant all privileges on database 'shop' to user 'alice' in MySQL CLI.
GRANT [1] ON [2].* TO '[3]'@'localhost';
SELECT instead of ALL PRIVILEGES for full access.Use GRANT ALL PRIVILEGES ON shop.* TO 'alice'@'localhost'; to give full access to the user on the database.