13.09.2016 Views

PHP and MySQL Web Development 4th Ed-tqw-_darksiderg

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

292 Chapter 12 Advanced <strong>MySQL</strong> Administration<br />

Table 12.3<br />

Field<br />

Continued<br />

Type<br />

Show_view_priv<br />

Create_routine_priv<br />

Alter_routine_priv<br />

Execute_priv<br />

Trigger_priv<br />

enum('N','Y')<br />

enum('N','Y')<br />

enum('N','Y')<br />

enum('N','Y')<br />

enum('N','Y')<br />

The tables_priv, columns_priv, <strong>and</strong> procs priv Tables<br />

The tables_priv, columns_priv, <strong>and</strong> procs_priv tables are used to store table-level<br />

privileges, column-level privileges, <strong>and</strong> privileges regarding stores routines, respectively.<br />

These tables have a slightly different structure than the user, db, <strong>and</strong> host tables have.<br />

The schemas for the tables_priv table, columns_priv table, <strong>and</strong> procs_priv table are<br />

shown in Tables 12.4, 12.5, <strong>and</strong> 12.6, respectively.<br />

Table 12.4<br />

Field<br />

Schema of the tables_priv Table in the mysql Database<br />

Type<br />

Host<br />

Db<br />

User<br />

Table_name<br />

Grantor<br />

Timestamp<br />

Table_priv<br />

Column_priv<br />

char(60)<br />

char(64)<br />

char(16)<br />

char(60)<br />

char(77)<br />

timestamp(14)<br />

set('Select', 'Insert', 'Update', 'Delete',<br />

'Create', 'Drop', 'Grant', 'References', 'Index',<br />

'Alter', 'Create View', 'Show view', 'Trigger'))<br />

set ('Select', 'Insert', 'Update', 'References')<br />

Table 12.5<br />

Field<br />

Schema of the columns_priv Table in the mysql Database<br />

Type<br />

Host<br />

Db<br />

User<br />

Table_name<br />

Column_name<br />

Timestamp<br />

Column_priv<br />

char(60)<br />

char(64)<br />

char(16)<br />

char(64)<br />

char(64)<br />

timestamp(14)<br />

set(‘Select’, ‘Insert’, ‘Update’, ‘References’)

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!