Introduction to Relational Database Systems 1 Lecture 4.

Slides:



Advertisements
Similar presentations
TWO STEP EQUATIONS 1. SOLVE FOR X 2. DO THE ADDITION STEP FIRST
Advertisements

LEUCEMIA MIELOIDE AGUDA TIPO 0
You have been given a mission and a code. Use the code to complete the mission and you will save the world from obliteration…
1 Copyright © 2010, Elsevier Inc. All rights Reserved Fig 2.1 Chapter 2.
1 Chapter 40 - Physiology and Pathophysiology of Diuretic Action Copyright © 2013 Elsevier Inc. All rights reserved.
By D. Fisher Geometric Transformations. Reflection, Rotation, or Translation 1.
Relational Database and Data Modeling
Business Transaction Management Software for Application Coordination 1 Business Processes and Coordination.
1 Copyright © 2005, Oracle. All rights reserved. Introduction.
Jeopardy Q 1 Q 6 Q 11 Q 16 Q 21 Q 2 Q 7 Q 12 Q 17 Q 22 Q 3 Q 8 Q 13
Jeopardy Q 1 Q 6 Q 11 Q 16 Q 21 Q 2 Q 7 Q 12 Q 17 Q 22 Q 3 Q 8 Q 13
Title Subtitle.
0 - 0.
ALGEBRAIC EXPRESSIONS
DIVIDING INTEGERS 1. IF THE SIGNS ARE THE SAME THE ANSWER IS POSITIVE 2. IF THE SIGNS ARE DIFFERENT THE ANSWER IS NEGATIVE.
MULTIPLYING MONOMIALS TIMES POLYNOMIALS (DISTRIBUTIVE PROPERTY)
ADDING INTEGERS 1. POS. + POS. = POS. 2. NEG. + NEG. = NEG. 3. POS. + NEG. OR NEG. + POS. SUBTRACT TAKE SIGN OF BIGGER ABSOLUTE VALUE.
SUBTRACTING INTEGERS 1. CHANGE THE SUBTRACTION SIGN TO ADDITION
MULT. INTEGERS 1. IF THE SIGNS ARE THE SAME THE ANSWER IS POSITIVE 2. IF THE SIGNS ARE DIFFERENT THE ANSWER IS NEGATIVE.
Addition Facts
Year 6 mental test 10 second questions Numbers and number system Numbers and the number system, fractions, decimals, proportion & probability.
Relational data objects 1 Lecture 6. Relational data objects 2 Answer to last lectures activity.
Introduction to SQL 1 Lecture 5. Introduction to SQL 2 Note in different implementations the syntax might slightly differ different features might be.
The ANSI/SPARC Architecture of a Database Environment
Views-basics 1. 2 Introduction a view is a perspective of the database different users may need to see the database differently; this is achieved through.
Query optimisation.
Active database concepts
Relational operators 1 Lecture 7 Relational Operators.
Relational data integrity
Normal forms - 1NF, 2NF and 3NF
1 Term 2, 2004, Lecture 6, Views and SecurityMarian Ursu, Department of Computing, Goldsmiths College Views and Security 3.
1 Term 2, 2004, Lecture 9, Distributed DatabasesMarian Ursu, Department of Computing, Goldsmiths College Distributed databases 3.
Data Definition and Integrity Constraints
Around the World AdditionSubtraction MultiplicationDivision AdditionSubtraction MultiplicationDivision.
ZMQS ZMQS
BT Wholesale October Creating your own telephone network WHOLESALE CALLS LINE ASSOCIATED.
Information Systems Today: Managing in the Digital World
ABC Technology Project
9 Copyright © 2004, Oracle. All rights reserved. Using DDL Statements to Create and Manage Tables.
Creating Tables. 2 home back first prev next last What Will I Learn? List and provide an example of each of the number, character, and date data types.
© S Haughton more than 3?
© Charles van Marrewijk, An Introduction to Geographical Economics Brakman, Garretsen, and Van Marrewijk.
© Charles van Marrewijk, An Introduction to Geographical Economics Brakman, Garretsen, and Van Marrewijk.
© Charles van Marrewijk, An Introduction to Geographical Economics Brakman, Garretsen, and Van Marrewijk.
Twenty Questions Subject: Twenty Questions
Linking Verb? Action Verb or. Question 1 Define the term: action verb.
Squares and Square Root WALK. Solve each problem REVIEW:
Energy & Green Urbanism Markku Lappalainen Aalto University.
Lets play bingo!!. Calculate: MEAN Calculate: MEDIAN
Past Tense Probe. Past Tense Probe Past Tense Probe – Practice 1.
Sets Sets © 2005 Richard A. Medeiros next Patterns.
Chapter 5 Test Review Sections 5-1 through 5-4.
Fundamentals of Database Systems Fourth Edition El Masri & Navathe
GG Consulting, LLC I-SUITE. Source: TEA SHARS Frequently asked questions 2.
1 First EMRAS II Technical Meeting IAEA Headquarters, Vienna, 19–23 January 2009.
Functional Dependencies and Normalization for Relational Databases
Addition 1’s to 20.
Model and Relationships 6 M 1 M M M M M M M M M M M M M M M M
25 seconds left…...
Test B, 100 Subtraction Facts
11 = This is the fact family. You say: 8+3=11 and 3+8=11
Week 1.
Number bonds to 10,
We will resume in: 25 Minutes.
©Brooks/Cole, 2001 Chapter 12 Derived Types-- Enumerated, Structure and Union.
1 Unit 1 Kinematics Chapter 1 Day
PSSA Preparation.
1 PART 1 ILLUSTRATION OF DOCUMENTS  Brief introduction to the documents contained in the envelope  Detailed clarification of the documents content.
13 Copyright © Oracle Corporation, All rights reserved. Controlling User Access.
Chapter 3 An Introduction to Relational Databases.
Presentation transcript:

Introduction to Relational Database Systems 1 Lecture 4

Introduction to Relational Database Systems 2 Relational database systems data objects relations / tables operators applied to tables generate tables

Introduction to Relational Database Systems 3 Relations / tables explicit data values extensionally defined atomic keys integrity design includes how to organise data in tables

Introduction to Relational Database Systems 4 Data about departments Depts

Introduction to Relational Database Systems 5 Data about employees Emps

Introduction to Relational Database Systems 6 Atomic values no access to individual items

Introduction to Relational Database Systems 7 Primary and foreign keys primary foreign

Introduction to Relational Database Systems 8 Integrity restrictions on data defined by users on individual tables age > 18; salary < 100k on more than one table if budget < 10M then salary < 50k implicit in the data model

Introduction to Relational Database Systems 9 Primary key integrity incorrect model

Introduction to Relational Database Systems 10 Foreign key integrity incorrect model ?

Introduction to Relational Database Systems 11 Relational operators characteristics set at a time base and derived tables closed with respect to relations / tables nested expressions include RESTRICT PROJECT JOIN

Introduction to Relational Database Systems 12 RESTICT RESTRICT Depts WHERE Budget > 8M

Introduction to Relational Database Systems 13 PROJECT PROJECT Depts OVER Dept_id, Budget

Introduction to Relational Database Systems 14 JOIN JOIN Depts AND Emps OVER Dept_id

Introduction to Relational Database Systems 15 Nested statements the members of all departments that have the budget greater than 7M JOIN (RESTRICT Depts WHERE Budget > 7M) AND Emps OVER Dept_id

Introduction to Relational Database Systems 16 Relational model a data model in which all data is modelled as relations a way of looking at data a prescription for a way of representing data manipulating data representing integrity constraints

Introduction to Relational Database Systems 17 Relational database systems relational DBMS implements the relational model not in its entirety may add new features relational database system a database application developed in the relational model and implemented in a relational DBMS physical details hidden from the user

Introduction to Relational Database Systems 18 Relational DBMS - features views security the optimiser the data catalogue / data dictionary

Introduction to Relational Database Systems 19 Views (in relational systems) named derived table the definition stored in the catalogue evaluated only when used optimisation used as if it were a real table problems with updates views ANSI/SPARC relational

Introduction to Relational Database Systems 20 Views CREATE VIEW TopEmp AS PROJECT (SELECT Emps WHERE Salary > 33K) OVER E_name, Salary

Introduction to Relational Database Systems 21 Views - usage SELECT TopEmp WHERE Salary <= 40 SELECT PROJECT SELECT Emps WHERE Salary > 33 OVER E_name, Salary WHERE Salary <= 40

Introduction to Relational Database Systems 22

Introduction to Relational Database Systems 23 Security and views how would you use the view mechanism in conjunction with the security system? DEFINE SECURITY RULE AS...

Introduction to Relational Database Systems 24 The optimiser operators - set level the DBMS decides how to best perform the operations, based on strategies of evaluation information about the DB (in the catalogue)

Introduction to Relational Database Systems 25 The best evaluation strategy PROJECT SELECT Emps WHERE E_id = E2 OVER E_name, Salary

Introduction to Relational Database Systems 26 The catalogue information about the database schemas mappings integrity rules views definition security rules... other modules that need it the optimiser the security system...

Introduction to Relational Database Systems 27 The system table Tables PROJECT Tables OVER Coulcount, Rowcount

Introduction to Relational Database Systems 28 The system table Columns

Introduction to Relational Database Systems 29 Summary relational model relations operators integrity relational DBMSs implement the relational model views + security the optimiser the catalogue next lecture : SQL