Relational Database Overview

in #technology6 years ago (edited)

snap (15).jpg

Hi, this is Oracle Girl and today we are going to clarify what is a Relational Database and how the object structures are related. RDBMS or relational database management system is the most widely used database in the world. The logical structures are represented using ER (entity-relationship) model. An ER model has three characteristics – entity, relationship, attributes.

snap (7).jpg

If we have “student” as an entity, then its attributes will be information that qualifies it. In our examples those attributes will be “name”, “grade” and “class”. We will create two more entities in order to demonstrate the remaining characteristic of the ER model – relationship.

snap (5).jpg

There are three types of relationships:
“One to one relationship” is grade and subject – a student can have only one grade in certain subject at the end of the year.

snap (8).jpg

“One to many relationship” – one student can be enrolled in many disciplines.

snap (9).jpg

“Many to many relationship”- one discipline can have different teachers and teachers can have different disciplines. Many-to-many relationships should not exist in RDBMS because they cannot represent a single row properly.

snap (10).jpg

In a relational database we need to be able to identify each occurrence of an entity uniquely. If we have two students or teachers with the same name we need a way to distinguish them. The easiest way is to add unique identifiers – like “stu_no”, “disc_no”, and “tea_no”.

snap (11).jpg

When we take the above logical model and create database objects representing the entities and the relationships, we create the physical model – Relational database. In the physical model each entity becomes a table and its attributes become columns of that table. The defined relationship between the entities is part of one or more constraints between the tables. They are implemented to enforce data integrity.

snap (12).jpg

Feel free to ask questions in the comments below if something is not clear enough.

snap (14).jpg

Regards,
Oracle Girl

Capture.JPG

Sort:  

Congratulations @oraclegirl! You have completed some achievement on Steemit and have been rewarded with new badge(s) :

You got your First payout
Award for the total payout received
Award for the number of upvotes

Click on any badge to view your own Board of Honor on SteemitBoard.

To support your work, I also upvoted your post!
For more information about SteemitBoard, click here

If you no longer want to receive notifications, reply to this comment with the word STOP

Upvote this notification to help all Steemit users. Learn why here!

You got a 28.07% upvote from @slimwhale courtesy of @prometheus21!

Did you know you can make a passive income by simply delegating steem power?
@slimwhale offers the best return on your investment, sharing 100% of the bidding pool rewards, daily, proportional to your investment.
Let's grow together, start earning now by clicking the following links: 10SP, | 50SP | 500SP, | any amount |
For more information, see here or join me on Discord

Coin Marketplace

STEEM 0.21
TRX 0.13
JST 0.030
BTC 67167.83
ETH 3499.47
USDT 1.00
SBD 2.81