Workshop

The quiz and exercises are provided to help you solidify your understanding of the material covered today. Try to understand the quiz and exercise answers before continuing to tomorrow's lesson.

Quiz

Consider the following GRANT statement, and use it to answer Quiz questions 1–4:

GRANT ALL
  ON mydb.*
  TO admin@localhost
1:What is not secure about the privileges set by this statement? Specify one way in which it's not secure.
A1: The user has no password set, so anyone at localhost will be able to log in as admin without a password.
2:Would the user admin be able to grant privileges to other users?
A2: No. Although ALL is specified, this does not include Grant_priv, which would have to be specified by appending WITH GRANT OPTION to the ...

Get Sams Teach Yourself MySQL in 21 Days, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.