Loading

Quipoin Menu

Learn • Practice • Grow

sql / SQL Security
mcq
Direction: Choose the correct option

Q1.

CREATE USER 'app_user'@'localhost' IDENTIFIED BY 'password';
What does this do?
A. Creates new database
B. Changes password
C. Creates new table
D. Creates new database user
Direction: Choose the correct option

Q2.

GRANT SELECT ON company.employees TO 'app_user'@'localhost';
What permission is granted?
A. All privileges
B. UPDATE only
C. INSERT only
D. SELECT on employees table
Direction: Choose the correct option

Q3.

GRANT INSERT, UPDATE ON company.* TO 'app_user'@'localhost';
What does company.* mean?
A. All columns
B. Company table
C. All databases
D. All tables in company database
Direction: Choose the correct option

Q4.

REVOKE DELETE ON company.employees FROM 'app_user'@'localhost';
What does REVOKE do?
A. Adds a permission
B. Removes a permission
C. Creates user
D. Deletes user
Direction: Choose the correct option

Q5.

How do you see a user's permissions?
A. DESCRIBE USER
B. SHOW PERMISSIONS
C. LIST GRANTS
D. SHOW GRANTS FOR user