Different Types of Database Languages:
Database language is an important part of DBMS. It is used to access the
required data from a database, to modify the data of database and to design the
structure of database. A user uses a database language for interfacing with the
DBMS to access the data from database. A user can either be an application
programmer or an end-user. Mostly, the application programmer
inserts the statements of the database access language into its program written
in general-purpose programming language (such as COBOL or C++ or Visual Basic or
any fourth-generation language (4GL)). It is because database access language is
also referred to as data sublanguage. Similarly, the database language does not
provide the complete programming language features. Many DBMSs have their own
The users use the database access language to enter new data, change the
existing data in database and to retrieve required data from databases. The user
writes a set of appropriate commands or statements in a database access language
and submits these to the DBMS. The DBMS translates the user commands and sends
them to a specific part of the DBMS called the Database Engine. The database
engine generates a set of results according to the commands submitted by user,
converts these into a user readable form called an Inquiry Report and then
displays them on the screen. The database administrators use the database access
language to create and maintain the databases.
The most popular database access language is SQL (Structured Query Language).
Relational Databases are required to have a database query language. Today most
of the RDBMSs use the SQL as database access language.
The sub-language is further divided into two major parts. These are:
(ii) Data Manipulation Language.
(i) Data Definition Language:
The data definition language is used to define the structure of database. The
DBA and database designer use the database language to define the conceptual and
internal schemas. Typically, the Data Definition Language (DDL) is used to.
define the conceptual schemas, whereas, Storage Definition Language (SDL) is
used to define the internal schemas. The mappings between the two schemas may be
defined in either of these languages. In most DBMSs, the DDL is used to define
both conceptual and external schemas. The DBMS has a DDL compiler, which
compiles the DDL statements and stores in the DBMS catalog known as data
(ii) Data Manipulation Language:
Once the database is designed and database is populated with data, the data
manipulation language (DML) is used to manipulate the database. In data manipulation, data is retrieved, inserted,
updated, and deleted to and from the database. It must be noted that DDL is not
used for data manipulation.
The application programmer can insert (or embed) the DML statements into the
program written in general-purpose language. Whenever, DML statements are
embedded in a general-purpose programming language that language is called the
Host Language and the DML is called the Data Sub-Language, In practice, the most
commonly used host languages are COBOL, C++, and Visual Basic etc. The host
language provides the facilities to perform computational operations. A given
DBMS might support any number of host languages and any number of data
sub-languages. The most popular data sub-language is SQL, which is supported by
almost all database systems.
In modern DBMSs, a comprehensive integrated database language is used which has
the combined features of DDL, VDL (View Definition Language) and DML. A typical
example of a comprehensive database language is the SQL relational database
There are two main types of Data Manipulation Language (.DML) These are:
(i) Non-Procedural DML
(i) Non-Procedural DML:
A high-level or non-procedural DML allows the user to specify what data is
required without specifying how it is to be obtained. Many DBMSs allow
high-level DML statements either to be entered interactively from a terminal or
to be embedded in a general-purpose programming language. The end-users use a
high-level query language to specify their requests to DBMS to retrieve data.
Usually, a single statement is given to the DBMS to retrieve or update multiple
records. The DBMS translates a DML statement into a procedure that manipulates
the set of records. The examples of non-procedural DMLs are SQL and QBE
(Query-By-Example) that are used by relational database systems. These languages
are easier to learn and use. The part of a non-procedural DML, which is related
to data retrieval from databases, is known as Query Language.
(ii) Procedural DML:
A low-level or procedural DML allows the user, i.e. programmer to specify what
data is needed and how to obtain-it. This type of DML typically retrieves
individual records from the database and processes each separately. In this
language, the looping, branching etc, statements are used to retrieve and
process each record from a set of records. The programmers use the low-level