3-Database Language and Interfaces
3-Database Language and Interfaces
By
Muhammad Usman
Database Language
Data definition language (DDL)
• Defines both schemas
Storage definition language (SDL)
• Specifies the internal schema
View definition language (VDL)
• Specifies user views/mappings to conceptual
schema
Data manipulation language (DML)
• Allows retrieval, insertion, deletion, modification
Database Language
Once the design of the database is completed and a DBMS is chosen to
implement the database, the first step is to specify conceptual and
internal schemas for the database and any mappings between the two.
In many DBMS where no strict separation of level is maintained, one
language called the “Data definition language” is used by the DBA
and the database designer to define both the schema(conceptual and
internal).
The DBMS will have a DDL compiler whose function is to process
DDL statements in order to identify the description of the schema
construct and to store the schema description in the DBMS catalogue.
Database Languages (cont.)
In DBMS where a clear separation is maintained between the conceptual
and internal levels. The DDL is used to specify the conceptual schema
only.
Another language, the storage definition language (SDL), is used to
specify the internal schema.
For a true three-schema architecture, we would need a third language,
the view definition language (VDL),to specify user views and their
mappings to the conceptual schema.
In most DBMSs the DDL is used to define both conceptual and external
schemas.
In relational DBMSs, SQL is used in the role of VDL to define user or
application views as results of predefined queries
Database Languages (cont.)
Once the database schema are compiled and the database is populated
with data, user must have some means to manipulate the database
(insertion, deletion and modification).
The DBMS provide a set of operation or a language called the “Data
Manipulation Language”.
There are two type of DML languages: