What Is RDBMS?: Microsoft Access Relational Database Management
What Is RDBMS?: Microsoft Access Relational Database Management
RDBMS stands for Relational Database Management System. RDBMS is the basis for SQL, and for all modern
database systems like MS SQL Server, IBM DB2, Oracle, MySQL, and Microsoft Access.
A Relational database management system (RDBMS) is a database management system (DBMS) that is
based on the relational model as introduced by E. F. Codd.
What is table?
The data in RDBMS is stored in database objects called tables. The table is a collection of related data entries
and it consists of columns and rows.
Remember, a table is the most common and simplest form of data storage in a relational database. Following is
the example of a CUSTOMERS table:
+----+----------+-----+-----------+----------+
| ID | NAME
| AGE | ADDRESS
| SALARY
+----+----------+-----+-----------+----------+
|
1 | Ramesh
32 | Ahmedabad |
2000.00 |
2 | Khilan
25 | Delhi
1500.00 |
3 | kaushik
23 | Kota
2000.00 |
4 | Chaitali |
25 | Mumbai
6500.00 |
5 | Hardik
27 | Bhopal
8500.00 |
6 | Komal
22 | MP
4500.00 |
7 | Muffy
24 | Indore
| 10000.00 |
+----+----------+-----+-----------+----------+
What is field?
Every table is broken up into smaller entities called fields. The fields in the CUSTOMERS table consist of ID,
NAME, AGE, ADDRESS and SALARY.
A field is a column in a table that is designed to maintain specific information about every record in the table.
1 | Ramesh
32 | Ahmedabad |
2000.00 |
+----+----------+-----+-----------+----------+
A record is a horizontal entity in a table.
What is column?
A column is a vertical entity in a table that contains all information associated with a specific field in a table.
For example, a column in the CUSTOMERS table is ADDRESS, which represents location description and
would consist of the following:
+-----------+
| ADDRESS
+-----------+
| Ahmedabad |
| Delhi
| Kota
| Mumbai
| Bhopal
| MP
| Indore
+----+------+
SQL Constraints:
Constraints are the rules enforced on data columns on table. These are used to limit the type of data that can
go into a table. This ensures the accuracy and reliability of the data in the database.
Constraints could be column level or table level. Column level constraints are applied only to one column where
as table level constraints are applied to the whole table.
Following are commonly used constraints available in SQL:
NOT NULL Constraint: Ensures that a column cannot have NULL value.
DEFAULT Constraint: Provides a default value for a column when none is specified.
CHECK Constraint: The CHECK constraint ensures that all values in a column satisfy certain
conditions.
INDEX: Use to create and retrieve data from the database very quickly.
Data Integrity:
The following categories of the data integrity exist with each RDBMS:
Referential integrity: Rows cannot be deleted, which are used by other records.
User-Defined Integrity: Enforces some specific business rules that do not fall into entity, domain or
referential integrity.
Database Normalization
Database normalization is the process of efficiently organizing data in a database. There are two reasons of the
normalization process:
Eliminating redundant data, for example, storing the same data in more than one tables.
Previous Page
Print Version
PDF Version
Next Page
First normal form (1NF) sets the very basic rules for an organized database:
Define the data items required, because they become the columns in a table. Place related data items
in a table.
INT
NOT NULL,
NOT NULL,
AGE
NOT NULL,
INT
ADDRESS
CHAR (25),
ORDERS
VARCHAR(155)
);
So if we populate this table for a single customer having multiple orders, then it would be something as follows:
ID
NAME
AGE
ADDRESS
ORDERS
100
Sachin
36
Cannon XL-200
100
Sachin
36
Battery XL-200
100
Sachin
36
Tripod Large
But as per 1NF, we need to ensure that there are no repeating groups of data. So let us break above table into
two parts and join them using a key as follows:
CUSTOMERS table:
CREATE TABLE CUSTOMERS(
ID
INT
NOT NULL,
NOT NULL,
AGE
NOT NULL,
INT
ADDRESS
CHAR (25),
ID
NAME
AGE
ADDRESS
100
Sachin
36
ORDERS table:
CREATE TABLE ORDERS(
ID
INT
NOT NULL,
CUSTOMER_ID INT
ORDERS
NOT NULL,
VARCHAR(155),
ID
CUSTOMER_ID
ORDERS
10
100
Cannon XL-200
11
100
Battery XL-200
12
100
Tripod Large
The dependency of nonprimary fields is between the data. For example, in the below table, street name, city, and state
are unbreakably bound to the zip code.
CREATE TABLE CUSTOMERS(
CUST_ID
INT
CUST_NAME
VARCHAR (20)
DOB
DATE,
STREET
VARCHAR(200),
CITY
VARCHAR(100),
STATE
VARCHAR(100),
ZIP
VARCHAR(12),
EMAIL_ID
VARCHAR(256),
NOT NULL,
NOT NULL,
);
The dependency between zip code and address is called a transitive dependency. To comply with third normal form, all
you need to do is move the Street, City, and State fields into their own table, which you can call the Zip Code table:
CREATE TABLE ADDRESS(
ZIP
VARCHAR(12),
STREET
VARCHAR(200),
CITY
VARCHAR(100),
STATE
VARCHAR(100),
INT
CUST_NAME
VARCHAR (20)
DOB
DATE,
ZIP
VARCHAR(12),
EMAIL_ID
VARCHAR(256),
NOT NULL,
NOT NULL,