Data Control Language (DCL)

Download as pdf or txt
Download as pdf or txt
You are on page 1of 24

Data Control Language (DCL)

Data Control Language

Data Control Language (DCL)


Data Control Language

Data Control Language (DCL)

the GRANT and REVOKE statements


Data Control Language

Data Control Language (DCL)

the GRANT and REVOKE statements


allow us to manage the rights users have in a database
Data Control Language
Data Control Language
Data Control Language

users
Data Control Language

The GRANT statement


Data Control Language

The GRANT statement


gives (or grants) certain permissions to users
Data Control Language

The GRANT statement


gives (or grants) certain permissions to users
Data Control Language

The GRANT statement


gives (or grants) certain permissions to users

GRANT type_of_permission ON database_name.table_name TO


‘username’@’localhost’
Data Control Language

The GRANT statement


gives (or grants) certain permissions to users

one can grant a specific type of permission, like complete or partial


access

GRANT type_of_permission ON database_name.table_name TO


‘username’@’localhost’
Data Control Language
these rights will be assigned to a person who has a username registered
at the local server (‘localhost’: IP 127.0.0.1)

GRANT type_of_permission ON database_name.table_name TO


‘username’@’localhost’
Data Control Language
these rights will be assigned to a person who has a username registered
at the local server (‘localhost’: IP 127.0.0.1)

big companies and corporations don’t use this type of server, and their
databases lay on external, more powerful servers

GRANT type_of_permission ON database_name.table_name TO


‘username’@’localhost’
Data Control Language

Database administrators
Data Control Language

Database administrators
people who have complete rights to a database
Data Control Language

Database administrators
people who have complete rights to a database
- they can grant access to users and can revoke it
Data Control Language

Database administrators
people who have complete rights to a database
- they can grant access to users and can revoke it

the REVOKE clause


Data Control Language

Database administrators
people who have complete rights to a database
- they can grant access to users and can revoke it

the REVOKE clause


used to revoke permissions and privileges of database users
Data Control Language

Database administrators
people who have complete rights to a database
- they can grant access to users and can revoke it

the REVOKE clause


used to revoke permissions and privileges of database users
- the exact opposite of GRANT
Data Control Language

the REVOKE clause


used to revoke permissions and privileges of database users
Data Control Language

the REVOKE clause


used to revoke permissions and privileges of database users

REVOKE type_of_permission ON database_name.table_name FROM


‘username’@’localhost’
Data Control Language

Next:
Data Control Language

Next:
Transaction Control Language (TCL)

You might also like