As we learned in the previous article, SQL or Structured Query Language is a programming language used to manage data in relational database. Now let us learn more about Relational Database Management System or RDBMS.
RDBMS Concepts – What is RDBMS
RDBMS is the abbreviation for Relational Database Management System which is the basis for SQL and for other modern databases such as MS SQL server, IBM, MySQL, DB2, Oracle and Microsoft Access. A database management system of DBMS based on the relational model introduced by E. F. Codd is called as Relational Database Management System or RDBMS.
What is a Table?
The database object where the data is stored in RDBMS is called as a table. A table consists of many columns and rows and it is a collection of related data entries. Table is the simplest form of data storage in RDBMS and it is the most common form too.
What is a Field?
Each table is divided into smaller entities called fields. A field can be defined as a column in a table which contains specific information about every record in table.
What is a Row and a Column?
A row is the horizontal entry in a table when a column is the vertical entry.
What is a Null Value?
A value in a field which is blank or a field with no value is called as Null Value. A null value is totally different from zero value or a field which contains “space”. When a field is left blank while recording, it is called as Null value.
The rules enforced on a data column in a table are called as constraints. These rules restrict the type of data that can go into a table and thus ensures reliability and accuracy of the database. The constraints can be table level or column level. Column levers constraints are confined to specific columns while the table level constraints can be applied to the entire table.
Here are some most widely used SQL constraints.
- Not Null Constraint: – This is to ensure that the column does not have a null value.
- Default Constraint: – When no value has been specified for a column, this constraint provides a default value.
- Unique Constraint: – This constraint is used to ensure that all the values in a column are unique ones.
- Primary Key: – This is used to identify each row or record in a database table.
- Foreign Key: – This is used to identify each row or record in any other data table.
- Check Constraint: – This constraint is for ensuring that all values in a column satisfy certain specified conditions.
- Index : – This is used to create and retrieve data from the table very easily.
Different categories of Data Integrity exist in RDBMS and they are as follows.
- Entity Integrity
- Domain Integrity
- Referential Integrity
- User-defined Integrity