Download presentation
Presentation is loading. Please wait.
1
Relational model characteristics
Information Technology 2nd year Mkhize N
2
Summary of prev. unit A data model is a (relatively) simple abstraction of a complex real-world data environment Basic data modeling components are: Entities Attributes Relationships Constraints Hierarchical model Depicts a set of one-to-many (1:*) relationships between a parent and its children segments Network data model Uses sets to represent 1:* relationships between record types
3
Summary of prev. unit Relational model *
Current database implementation standard ER model is a popular graphical tool for data modeling that complements the relational model Object is basic modeling structure of object oriented data model The relational model has adopted many object-oriented extensions to become the extended relational data model (ERDM) Data modeling requirements are a function of different data views (global vs. local) and level of data abstraction NoSQL databases are a new generation of databases that do not use the relational model and are geared to support the very specific needs of Big Data organizations
4
Summary of prev. unit Big Data business rule conceptual model entity
A movement to find new and better ways to manage large amounts of Web-generated data and derive business insight from it, while simultaneously providing high performance and scalability at a reasonable cost. business rule A description of a policy, procedure, or principle within an organization. For example, a pilot cannot be on duty for more than 10 hours during a 24-hour period, or a professor may teach up to four classes during a semester. conceptual model The output of the conceptual design process. The conceptual model provides a global view of an entire database and describes the main data objects, avoiding details. entity A person, place, thing, concept, or event for which data can be stored. See also attribute. NoSQL A new generation of database management systems that is not based on the traditional relational database model.
5
What is relational model?
Developed by E. F. Codd of IBM in 1970, it represented a major breakthrough for users and designers because of its conceptual simplicity. The relational model is based on mathematical set theory and represents data as independent relations. Each relation (table) is conceptually represented as a matrix of intersecting rows and columns. The relations are related to each other through the sharing of common entity characteristics (values in columns). relational database model offers a logical view of data
6
Logical view of data The practical significance of taking the logical view is that it serves as a reminder of the simple file concept of data storage. Although the use of table, quite unlike that of the file, has the advantages of structural and data independence, a table does resemble a file from a conceptual point of view.
7
Tables & their characteristics
The logical view of the relational database is facilitated by the creation of data relationships based on a logical construct known as a table. A table is perceived as a two-dimensional structure composed of rows and columns. A table contains a group of related entities; A table is also called relation because of the relational model’s model. Within the relational model, columns of tables are referred to as attributes and rows of tables are known as tuples.
9
What is a relation? The concept of a relation is modelled on a mathematical construct. In mathematics, a relation is formally defined as: Given a number of sets D1, D2, ....., Dn (which are not necessarily distinct), R is a relation on these n sets, it is a set of tuples each of which has its first element from D1, second element form D2, and so on.
10
Example of a relation Assume we have two sets (n =2), one of student’s last names (STU_LNAME) and one of the department codes (DEPT_CODE) where they have enrolled. STU_LNAME {Dlamini, Madonda, Bux, Robertson} DEPT_CODE {BIOL, CIS, EDU} Then a relation can be defined over the sets STU_LNAME and DEPT_CODE as: R = {(Dlamini, BIOL), (Madonda, CIS),(Bux, EDU),(Robertson, EDU)}
11
Tables and relations Table: two-dimensional structure composed of rows and columns Contains group of related entities = an entity set Terms entity set and table are often used interchangeably Table also called a relation because the relational model’s creator, Codd, used the term relation as a synonym for table Think of a table as a persistent relation: A relation whose contents can be permanently saved for future use
13
Attribute and domains Each attribute is a named column within the relational table and draws its value from a domain, which is a set of possible values for this attributes. The domain of values for an attribute should contain only atomic values and one value should not be divisible into components. No attributes with more than one value be allowed. Each domain is also defined by its data type. What is a Domain? In data modelling, the construct used to organize and describe an attribute’s set of possible values.
14
Degree and cardinality
Degree and Cardinality are two important properties of the relational model. A relation with N columns = Degree N and N rows = cardinality N The degree of the relation is the number of its attributes and The cardinality of a relation is the number of its tuples.
16
summary Relations are basic building blocks of a relational database.
Keys are central to the use of relational tables Keys define functional dependencies Superkey Candidate key Primary key Secondary key Foreign key Each table row must have a primary key which uniquely identifies all attributes Tables can be linked by common attributes. Thus, the primary key of one table can appear as the foreign key in another table to which it is linked Good design begins by identifying appropriate entities and attributes and the relationships among the entities. Those relationships (1:1, 1:*, and *:*) can be represented using ERDs.
17
Homework #1 Group One presentation: Relational Schema Keys
Relational Database Keys Controlled Redundancy Group Two Presentation: Data Dictionary and the system catalogue Relationships within the Relational Database The 1:1 Relationship and the *:* Relationship Indexes and Codd’s Relational Database Rules
18
Thank you for coming In life the everlasting joy is to know that you have carried others on your shoulders to get on the other side to advanced their career vision. ~ Nkosy Light
Similar presentations
© 2024 SlidePlayer.com Inc.
All rights reserved.