Introduction
RDBMS stands for Relational Database Management System. RDBMS is a database management system based on the relational model introduced by E.F Codd in the 1970s. The major DBMS like SQL, My-SQL, ORACLE are all based on the principles of relational DBMS.
Commonly used terms in Relational Models
Widely used terms in Relational Model are -
Table or Relation: The table is also known as relation. The table consists of one or more columns and each column has a unique name. Each table contains a record of a particular type and each record type defines a fixed number of fields or attributes.
For Example:
Roll No |
Name |
Marks |
Phone |
001 |
AAAA |
88 |
1111111111 |
002 |
BBBB |
83 |
222222222 |
003 |
CCCC |
98 |
333333333 |
004 |
DDDD |
67 |
444444444 |
Tuple or record or row: Rows are called tuples in a relational database. These are also called records. In a relation there should not be two same tuples. One of the tuples can be represented by
001 |
AAAA |
88 |
1111111111 |
Attributes: Attributes are nothing but columns in a relational database. They are also called Fields. For example, the above table consists of four attributes: RollNo, Name, Marks, and phone.
Relation Instance: It refers to a relational database that has some integrity constraints. For example- the following is a relation instance - which contains the records with age above 18.
Roll No |
Name |
Age |
Adhar Card |
1 |
Amisha |
19 |
1111111111 |
2 |
Bhavisha |
20 |
222222222 |
3 |
Charmi |
19 |
333333333 |
Domain: For each attribute of the relational table, there is a set of valid values called domain. For example - in the above table, the domain of the Name attribute is all possible names of students. But the Domain of Age attributes is (19,20)
Atomic: The domain is atomic if elements of the domain are considered to be indivisible units. For example, in the above table, the attribute Adhar Card is non-atomic.
NULL attribute: A null is a special symbol, independent of data type, which means either unknown or inapplicable. It does not mean zero or blank. For example - Consider a salary table that contains NULL.
EMP |
Job Name |
Salary |
Commission |
E10 |
Sales |
12500 |
32090 |
E11 |
Null |
25000 |
8000 |
E12 |
Sales |
44000 |
0 |
E13 |
Sales |
44000 |
Null |
Degree: It is nothing but the total number of columns present in the relational database. In a given Student table - Degree is 4
Roll No |
Name |
Marks |
Phone |
001 |
AAAA |
88 |
1111111111 |
002 |
BBBB |
83 |
222222222 |
003 |
CCCC |
98 |
333333333 |
Cardinality: Cardinality is the number of tuples/rows present in the relational database. In the above-given table, the cardinality is 3.