You are on page 1of 8

DATABASE LANGUAGES

WHAT IS DATABASE MANAGEMENT SYSTEM


A Database Management System(DBMS) is system software for creating and
managing database. The DBMS provides users and programmers with a systematic
way to create, retrieve, update and manage data.

# In DBMS we have 3 types of Languages:


• Data Definition Language(DDL).
• Data Manipulation Language(DML).
• Data Control Language(DCL).
DATA DEFINITION LANGUAGE
• Database language that is used to Create, Delete or modify database schema is
called Data Definition Language(DDL).
• It is used by Database Administrator (DBA) to specify the conceptual schema.
• DDL interpreter converts DDL statements into equivalent low level statements
understood by the DBMS.
• Normally create, alter and drop statements are DDL commands.
• DDL commands make changes in the schema.
Example for create
command Example for drop
command
create table Student(
sid number(4), Drop Student;
sname varchar2(50),
DOB varchar2(20));

Example for alter command

Alter table Student


ADD COLUMN address
varchar2(50);
DATA MANIPULATION LANGUAGE(DML)

• Database language that enables insert, update, delete, and retrieval of


data from the database is called Data Manipulation Language.
• DML compiler converts DML statements into equivalent low level
statements that the database understands.
• Normally insert, update, delete, select are DML commands.
• DML reflects change in the instance not the schema.
Example for insert Example for update
Insert into student Update student set class=11
values(“A-0010”, where sid=“A-0010”;
“Akash”, 10);

Example for delete Example for select

Delete from student Select * from student


where sname=“Raj”;
DATA CONTROL LANGUAGE (DCL)

DCL statements control access to data and the database using the statements
such as GRANT, and REVOKE. A privilege can either be granted to a User
with the help of GRANT statement. The privilege assigned can be SELECT,
ALTER, DELETE, EXECUTE, INSERT, INDEX, etc. In addition to granting of
privileges, you can also revoke (take back) it by using REVOKE command.
THANK
YOU
BY: L VINAY KUMAR
REDDY
CLASS: 2ND SEM BCA

You might also like