sql server ___________data control language

Post on 20-Jan-2017

166 Views

Category:

Education

7 Downloads

Preview:

Click to see full reader

TRANSCRIPT

DATA CONTROL LANGUAGE

DCL

DCL is used to control permission on database objects. DCL statements are used to take care of the security and

authorization. Types of DCL statements are as follows

a. Grant statement b. Revoke statementc. Deny statment

Grant statment

Grant privilege (rights which are to be allocated ) is used when database is to be shared with other users, with certain types of rights granted to the users.

Permissions are controlled by using the grant and revoke statements and deny statement.

Grant {all | statements} On table_nameTo security_account

Example:Grant select on employee to john

Revoke statement

Revoke statement removes a previously granted or denied permission from a user in the current database

Revoke {all | statement}On table_nameFrom security_acccount

Example :Revoke select on employee from john

Deny statement

The deny statemant creates an entry in the security system that denies a permission from a security account in the current database and prevents the security account from inheriting the permission through its group or role membership.

Deny {all | statement}On table_nameTo security_account

Example:Deny select on employee to john

top related