VOOZH about

URL: https://www.geeksforgeeks.org/sql/dcl-full-form/

⇱ DCL Full Form - Data Control Language - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

DCL Full Form - Data Control Language

Last Updated : 27 Dec, 2025

The full form of DCL is Data Control Language in Structured Query Language (SQL). DCL commands are used to control privileges in the database. The privileges (right to access the data) are required for performing all the database operations, like creating tables, views, or sequences. DCL statements are used to perform the work related to the rights, permissions, and other controls of the database system.

👁 frame_3310

There are two types of privileges in the database:

  • System Privilege
  • Object Privilege

Need Of DCL commands

  • Unauthorized access to the data should be prevented in order to achieve security in our database
  • DCL commands maintain the database effectively than anyone else other than database administrator is not allowed to access the data without permission.
  • These commands provide flexibility to the data administrator to set and remove database permissions in granular fashion.

Commands in DCL

The two most important DCL commands are GRANT and REVOKE.

GRANT

This command is used to grant permission to the user to perform a particular operation on a particular object. If we are a database administrator and we want to restrict user accessibility such as one who only views the data or may only update the data.

we can give the privilege permission to the users according to our wish.

Syntax

GRANT privilege_list
ON Object_name
TO user_name;

REVOKE

This command is used to take permission/access back from the user. If we want to return permission from the database that we have granted to the users at that time we need to run REVOKE command.

Syntax

REVOKE privilege_list
ON object_name
FROM user_name;

Following commands are granted to the user as a Privilege List:

Advantages Of DCL commands:

  • It allows to restrict the user from accessing data in database.
  • It ensures security in database when the data is exposed to multiple users.
  • It is the wholesome responsibility of the data owner or data administrator to maintain the authority of grant and revoke privileges to the users preventing any threat to data.
  • It prevents other users to make changes in database who have no access to Database

Disadvantages Of DCL commands:

  • DCL targets only restriction of access, while other functions like manipulation of data are not available.
  • One can end up assigning privileges to the wrong users by improper use of GRANT and may not revoke unnecessary privileges using REVOKE, which can make the data vulnerable to unauthorized users.
  • Handling permissions becomes challenging, especially since databases are large in the current world.
  • DCL cannot perform INSERT, UPDATE, or DELETE statements.
  • DCL is only useful when DML and DDL operations have already been performed.
Comment
Article Tags:
Article Tags: