0% found this document useful (0 votes)
5 views3 pages

ACTIVITY 2_Database Relational Model

The Database Relational Model, introduced by Edgar F. Codd in 1970, organizes data into tables (relations) consisting of rows (tuples) and columns (attributes), ensuring data integrity and efficient retrieval through SQL. Key components include relations, tuples, attributes, domains, primary keys, and foreign keys, which facilitate data management and relationships between tables. This model is fundamental in various real-world applications like banking and healthcare, underpinning popular database systems such as MySQL and PostgreSQL.

Uploaded by

reymondabno
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views3 pages

ACTIVITY 2_Database Relational Model

The Database Relational Model, introduced by Edgar F. Codd in 1970, organizes data into tables (relations) consisting of rows (tuples) and columns (attributes), ensuring data integrity and efficient retrieval through SQL. Key components include relations, tuples, attributes, domains, primary keys, and foreign keys, which facilitate data management and relationships between tables. This model is fundamental in various real-world applications like banking and healthcare, underpinning popular database systems such as MySQL and PostgreSQL.

Uploaded by

reymondabno
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

MORTEGA, REYMOND S.

IS2-1-01

ACTIVITY 2 : Database Relational Model

Individual Activity: Database Relational Model

Define the Database Relational Model

 Explain what the relational model is and why it is important in database management.

The Relational Model, proposed by Edgar F. Codd in 1970, provides an organized manner to
organize and manage data using tables made up of rows (records) and columns (attributes).
This model is essential for database management because it provides data integrity,
consistency, and efficient retrieval via SQL, a language later developed by Donald D.
Chamberlin and Raymond F. Boyce. Codd’s work, which was later refined by Chris Date, set the
groundwork for modern database systems such as MySQL, PostgreSQL, and Oracle, which use
relational principles to store and handle vast volumes of structured data efficiently.

Key Components of the Relational Model (Define and provide examples of the following)

 Relation (Table)- Relation (table) A relation, often known as a table, is a set of data
structured into rows and columns. It refers to a distinct entity, such as students or
employees. For example a Students database with columns like Student_ID, Name,
Age, and Course.

 Tuple (Row/Record)- Tuple (row/record). A tuple is a single row in a table that


represents an individual entry or record. Each tuple holds data for a single entity
instance. For example, a tuple in the Students database could be (101, Alice, 20,
Computer Science).

 Attribute (Column/Field)- An attribute is a column in a table that contains a certain type


of data. Each attribute is named and defines a property of the entity. For example, in the
Students table, the Name attribute stores student names.

 Domain – Domain A domain is the collection of all the values that an attribute can take.
It maintains data consistency by limiting the types of values allowed in a column. For
example, the Age attribute in the Students table may only accept integers between 18
and 30.
 Primary Key- A primary key is a unique identifier for every record in a table. It assures
that no two rows share the same value in this column. For example, Student_ID in the
Students table is a primary key since each student has a unique ID.

 Foreign Key- A foreign key is a table attribute that links to another table’s primary key. It
maintains referential integrity among connected tables. For example, a Course_ID in the
Students table can be used as a foreign key to the Courses table.
Operations in the Relational Model

 Briefly explain and give an example of each of the following relational operations:

SELECT (σ) – Selection: The selection operation retrieves rows (tuples) from a table that meet
a specific condition.

Example: To find students who are 20 years old:

σ(Age = 20) (Students)

PROJECT (π) – Projection: The projection operation retrieves specific columns (attributes)
from a table, removing duplicates.

Example: To display only Student_ID and Name from the Students table: π(Student_ID, Name)
(Students)

UNION ( ∪ ): The union operation combines the results of two tables with the same structure,
removing duplicates.

from both: Students1 ∪ Students2


Example: If there are two tables, Students1 and Students2, the union will list all unique students

INTERSECT ( ∩ ): The intersect operation returns the common rows that appear in both tables.

Example: To find students present in both Students1 and Students2 tables: Students1 ∩
Students2

DIFFERENCE ( - ): The difference operation returns rows that exist in one table but not in
another.

Example: To find students in Students1 but not in Students2: Students1 - Students2

CARTESIAN PRODUCT ( × ): The Cartesian product combines every row from the first table
with every row from the second table, creating a new table with all possible combinations.

Example: If Students has 3 rows and Courses has 2 rows, their Cartesian product will have 3 ×
2 = 6 rows: Students × Courses

JOIN: The join operation combines related rows from two tables based on a common attribute
(foreign key).

Example: To join Students and Courses using Course_ID: Students ⨝ Courses ON


Students.Course_ID = Courses.Course_ID.
Conclusion:

 Summarize your learnings and discuss the importance of the relational model in real-
world

Database application

The Relational Model is a key idea in database administration that divides data into organized
tables (relations) with rows (tuples) and columns (attributes). It uses relational operations like as
SELECT, PROJECT, JOIN, and UNION to assure data integrity, consistency, and rapid retrieval.
The model also employs keys (primary and foreign) to maintain relationships between tables,
reducing redundancy and improving data accuracy. The relational model is widely used in real-
world applications such as banking, healthcare, e-commerce, and education to efficiently
manage large amounts of structured data. This paradigm is used by popular databases such as
MySQL, PostgreSQL, and Oracle to store and retrieve data in a safe, scalable, and reliable
manner. Its capacity to conduct complicated queries, manage relationships, and impose
restrictions makes it a crucial component of any modern database application.

You might also like