This DBMS tutorial series will provide you an overview of database management system, it’s architecture etc. You will go through different ways to create or manipulate (ADD, DELETE, UPDATE) data in the database. In this article, we will go through introduction to database. In the coming posts, we will learn more about database.
A database is a collection of Coherent & meaningful data. They are used to store information in table like structure.
If you still cannot figure out what is coherent & what the definition says, let’s look at an example.
For example: Say you want to store information of all the employees in a company. To store information related to each employee, you should have Employee Name, Employee joining date, Employee Age, Contact number, Salary etc. This can be termed as coherent collection of data. It means they are logically similar and forms a unified group.
Database contains tables and each table stores similar information. Does that sound confusing! Let’s take an example of YouTube which is the most popular video viewing & streaming website at least in 2018 🙂 . Youtube stores massive information about usernames, videos, comments and various other data.
It would be difficult to store such huge and valuable information in random notepad or word files. Hence, Youtube stores the data in tables to organize similar information. So, the information similar to users will be stored in Users table, all video information will be stored in Videos table and likewise. Now, you must be wondering what are tables here! Let’s have a look.
What are tables in a database?
Tables are like grid made up of rows and columns. Columns are like categories. Each entry in a table goes in a separate row. Let’s say, i want to have a table having information about my friends and some information about them.
Name | Age | Profession | Salary(in INR) |
---|---|---|---|
Vikash | 28 | Software Engineer | 50000 |
Arnav | 29 | Mechanical Engineer | 30500 |
Amit | 32 | Journalist | 25000 |
All the name information will go to Name column, Age information will go to Age column. So the columns here are Name, Age, and Profession & Salary(in INR).
Some day you want to find out what your friend Amit does, so you can directly look at the table to find out the profession. This is how easy it becomes to find out specific information if you organize the data in tables rather than looking at the random data stored in files.
If you actually take a look at some complex example like storing information about every citizen in India. You add millions of rows in the table and some day you wish to find out information about a person named Arnav. Probably you may find thousands of rows with the name Arnav and it will become difficult to find out which row is the one you were looking for. So you try to find the rows with name Arnav and whose profession is Mechanical engineer. You may find 500 rows which matches this criteria. To solve this problem, you need to make each an every row unique. To maintain the uniqueness of each row, we need to have a primary key. So, you can consider your Aadhar number as your primary key (Aadhar number is for India).
What is a primary key?
AadhaarNumber | Name | Age | Profession | Salary(in INR) |
---|---|---|---|---|
4564532131 | Vikash | 28 | Software Engineer | 50000 |
45566532131 | Arnav | 29 | Mechanical Engineer | 30500 |
4564532134 | Amit | 32 | Journalist | 25000 |
All tables should have a primary key column & primary key should have all unique values. No rows can have same primary key (E.g. No 2 citizens will have same Aadhaar number). So If want to find out all information for Arnav, you need to have just a single value i.e. Primary key (AadhaarNumber in this case). Now that we have discussed some vital information demystifying about tables, columns, rows etc we will look at what DBMS is.
What is a Database management system (DBMS)?
Database management system is a system that allows inserting, updating, deleting & processing the data. It also enables users to create and maintain a database. In short to manage all your data, tables, database and various other aspects we need a DBMS. Some of the DBMS systems out there are MySQL, SQLite, DB2, Sybase, MS Access, Oracle, and
Microsoft’s SQL Server etc.
Below are Advantages of DBMS
- Duplication of data can be reduced.
- Consistency can be achieved. Any changes made to the database are immediately reflected to the users.
- New categories of data can be added to the database without disrupting the existing system and applications can be insulated from how data is structured and stored.
- Data Integrity can be maintained by ensuring that database contains only accurate data.
- Security of data can be implemented.
- Stored data can be used by single or multiple users.
- Sharing of data is possible through various level of authorization. The data can be shared based on correct authorization protocol.
- Backup of data can be created based on the requirements. Hence the users don’t need to worry about accidental the loss of data. Even if the data is lost, the data can be restored with the data that was backed up.
You must be logged in to post a comment.