Database Reference
In-Depth Information
Figure 12.1
Format of the user system table.
Figure 12.1 shows the format of this table. Note that there are rows for the username and
password, as well as rows for specific access privileges.
The content of the table is revealed by the following:
SELECT *
FROM
USER
Figure 12.2 shows some of the contents of the table. You will see that during the produc-
tion of this topic there has only really been one user created, with other root users that are
system generated.
You will also see that the root user in this instance does not have a password and the
password for the user called mafiu is not the one that you may have been typing in through-
out the topic. For security, MySQL encrypts a password before it gets stored within a table.
You can see the benefit of this when other users can access the user table and view each
other's passwords.
When you grant a privilege to a user, if the user does not already exist it will create an
entry in the user table. If they already exist then the privilege will be added to the existing
user.
Search WWH ::




Custom Search