+ All Categories
Home > Documents > Database Management System Lecture

Database Management System Lecture

Date post: 06-Apr-2018
Category:
Upload: mara-sarabia
View: 223 times
Download: 0 times
Share this document with a friend
48
Data facts, text, graphics, images, sound, and video segments that have meaning in the user s environment. Example: a listing of students Information data that have been processed in such a way as to increase the knowledge of the person who uses the data. Example: student data coul d be analyzed and summarized through the use of statistical measures. Metadata data that describe the properties or characteristics of other data but do not include that data. Some of these properties incl ude data definitions, data structures, and rules or constraints.
Transcript
Page 1: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 1/49

Data facts, text, graphics, images, sound, and video segments that havemeaning in the user s environment.

Example: a listing of studentsInformation data that have been processed in such a way as to increase theknowledge of the person who uses the data.

Example: s tudent data could be analyzed and summarizedthrough the use of statistical measures.Metadata data that describe the properties or characteristics of other databut do not include that data. Some of these propert ies include datadefinitions, data structures, and rules or constraints.

Page 2: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 2/49

NAME TYPE LENGTH DESCRIPTIONCOUR

SE TEXT 20COUR

SE NAMESEC TIO N INTEGER 1 SEC TIO N

NU MBER

NAME TEXT 20 STU DENT NAMESEMESTER TEXT 10 SEMESTER AND

YEA R

GPA DEC IMAL 4 STU DENT GR ADEPO INT AVER AGE

Page 3: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 3/49

1. C haracter2. Field3. R ecord4. File5.

Database an organized collection of logically related data.Data System employ a combination of persons, methods and materialsto process raw data about an enterprise into significant informationso as to providea basis for management decision.

Data Element general class or category of data also known as data item,data field or attributes.

Key Data Element data element that uniquely identifies the record.Data R ecord collection of values taken by related data element.Data File collection of data records.

Page 4: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 4/49

Database Approach emphasizes the integration andsharing of data across the organization. Thisapproach requires a major reorientation inthought process (paradigm shift), starting withtop management.

Database Application an application program (or setof related programs) that is used to perform aseries of database activities(create, read, update,delete) on behalf of database users.

Page 5: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 5/49

1. Personal databases designed to supportone user.2. Workgroup databases databases wherein a relatively small team of

people collaborate on the same project or application or on a group of similar projects or applications.

3. Department databases designed to support the various functions

and activities of a department.4. Enterprise databases databases whose scope is the entire

organization or enterprise intended to support organization-wideoperations and decision making.

a. Enterprise resource planning(E R P) systems a business

management system that integrates all functions of the enterprise,such as manufacturing, sales, finance, marketing, inventory,accounting, and human resources.b. Data warehouse an integrated decision support database whosecontent is derived from the variousoperational databases.

Page 6: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 6/49

Legacy data data contained by a system used prior to the installation of a new system.

5. Extranet database database which uses Internet protocols to establishlimited access to company data and information by the company s

customersand suppliers.6. Intranet database database which uses Internet protocols to establish

access to company data and information that is limited to theorganization.

7. Internet database database which uses Internet protocols to establish

universal access to company data and information.

Page 7: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 7/49

1. Program-data independenceData independence separation of data descriptions from the

application programs that uses the data.2. Minimal data redundancy 3. Improved data redundancy 4. Improved data sharing5. Increased productivity of application development

Page 8: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 8/49

6. Enforcement of standards7. Improved data quality

C onstraint a rule that cannot be violated by database users.8. Improved data accessibility and responsiveness9. R educed program maintenanceMaintenance refers to modifying or rewriting old programs to make

them conform to new data formats, access methods and so forth.

Page 9: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 9/49

Page 10: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 10/49

1. C omputer-Aided Software Engineering Tools ( C ASE) automated toolsused to design databases and application programs.

2. R epository centralized knowledge base containing all data definitions,screen and report formats, and definitions of other organizations andsystem components.

3. Database Management System (DBMS)- commercial software system used to create, maintain and providecontrolled access to the database and also to the repository.

4. Database a shared collection of logically related data.

5. Application programs computer programs that are used to create andmaintain the database and provide information to users.

Page 11: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 11/49

6. U ser interface languages, menus and other facilities by which usersinteractwith various system components.

7. Data Administrators persons who are responsible for the over-allinformation resources of an organization.

8. System Developers persons such as system analysts andprogrammerswho design new application programs.

9. End U sers persons throughout the organization who add, delete,and modify data in the database and who request or receiveinformation from it.

Page 12: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 12/49

Project Identificationand Selection

Project Initiation andPlanning

Analysis

Logical DatabaseDesign

Enterprise data model

C onceptual data model

Logical data model

Page 13: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 13/49

Physical DatabaseDesign

Implementation

Maintenance

Technology model

Databases and repositories

Page 14: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 14/49

1. Enterprise modeling the first step in database development in which the scope and general contents of a database are specified.

2. C onceptual database design analysis of the over-all datarequirements for a specific information system. This system might bethe topic of a particular user request to modify an existing system orto build a new system, or it might be the result of the identificationof a new database from enterprise modeling.

3. Logical database design perform the detailed review of thebusiness processes supported by the database, analyze eachindividual report, transaction and so on.

4. Physical database design and creation decide on the organizationof the database in computer storage and define the physicalstructures to the database management system.

5. Database implementation writing, testing and installing theprograms that process the database for data capture and reporting.

Page 15: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 15/49

6. Database maintenance evolve the database. Add, delete, or changecharacteristics of the structure of a database in order to meetchanging business conditions, to correct errors in database designmade in earlier steps or to improve the processing speed of adatabase applications.

Page 16: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 16/49

A database security manager is the most important asset to maintainingand securing sensitive data within an organization. Database security managers are required to multitask and juggle a variety of headachesthat accompany the maintenance of a secure database.

If you own a business it is important to understand some of the databasesecurity problems that occur within an organization and how to avoidthem. If you understand the how, where, and why of database security you can prevent future problems from occurring.

Page 17: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 17/49

Database Security Issuesy Daily Maintenance: Database audit logs. These unauthorized

applications are often difficult to identify and allow hackers acquiredaily review to make certain that there has been no data misuse. This

requires overseeing database privileges and then consistently updatinguser access accounts. A database security manager also providesdifferent types of access control for different users and assesses newprograms that are performing with the database. If these tasks areperformed on a daily basis, you can avoid a lot of problems with usersthat may pose a threat to the securityof the database.

Page 18: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 18/49

y Varied Security Methods for Applications: More often than notapplications developers will vary the methods of security for differentapplications that are being utilized within the database. This can createdifficulty with creating policies for accessing the applications. Thedatabase must also possess the proper access controls for regulating the varying methods of security otherwise sensitive data is at risk.

y Post- U pgrade Evaluation: When a database is upgraded it is necessary for the administrator to perform a post-upgrade evaluation to ensurethat security is consistent across all programs. Failure to perform thisoperation opens up the database to attack.

Page 19: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 19/49

y Split the Position: Sometimes organizations fail to split the dutiesbetween the IT administrator and the database security manager.Instead the company tries to cut costs by having the IT administratordo everything. This action can significantly compromise the security of the data due to the responsibilities involved with both positions. The ITadministrator should manage the database while the security managerperforms all of the daily security processes.

y Application Spoofing: Hackers are capable of creating applications thatresemble the existing applications connected to the database. Theseunauthorized applications are often difficult to identify and allowhackers access to the database via the application in disguise.

Page 20: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 20/49

y Manage U ser Passwords: Sometimes IT database security managers will

forget to remove IDs and access privileges of former users which leadsto password vulnerabilities in the database. Password rules andmaintenance needs to be strictly enforced to avoid opening up thedatabase to unauthorized users.

y Windows O S Flaws: Windows operating systems are not effective whenit comes to database security. O ften theft of passwords is prevalent as well as denial of service issues. The database security manager can takeprecautions through routine daily maintenance checks.

These are just a few of the database security problems that exist withinorganizations. The best way to avoid a lot of these problems is toemploy qualified personnel and separate the security responsibilitiesfrom the daily database maintenance responsibilities.

Page 21: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 21/49

The most important security measures of data management softwarefollows:

1. Views or subschemas, which restrict user views of the database. A view is a subset of the database that is presented to one or more users.

It is created by querying one or more of the base tables, producing adynamic result table for the user at the time of the request.

2. Domains, assertions, checks, and other integrity controls defined asdatabase objects, which are enforced by the DBMS during databasequerying and updating. Integrity controls protect data fromunauthorized use and update. They limit the values a field may hold,limit the actions that can be performed on data, or trigger theexecution of some procedure, such as placing an entry in a log torecord which users have done what with which data.

Domain a way to create a user-defined data type. O nce a domain isdefined, any field can be given that domain as its data type.

Assertion powerful constraint that enforce certain desirable databaseconditions.

Page 22: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 22/49

Trigger includes an event, condition, and action which can do thefollowing:

y

Prohibit inappropriate actionsy C ause special handling procedures to be executedy C ause a row to be written to a log file to echo important information

about the user and a transaction being made to sensitive data.3. Authorization rules, which identify users and restrict the actions they

may take against a database. These are controls incorporated in thedata management system that restrict access to data and also restrictthe actions that people may take when they access data.

4. U ser-defined procedures, which define additional constraints orlimitations in using a database. Some DBMS products provide user

exits (or interfaces) that allow system designers or users to createtheir own user-defined procedures for security.

Page 23: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 23/49

5. Encryption procedures, which encode data in an unrecognizableform.

Encryption the coding or scrambling of data so that humans cannotread them.6. Authentication schemes, which positively identify a person

attempting to gain access to a database.7. Backup, journaling, and checkpointing capabilities, which facilitate

recovery procedures.Database recovery is data administration s response to Murphy s law. A

database management system should provide four basic facilities forbackup and recovery of a database:

1. Backup facilities, which provide periodic backup copies of portions of

or the entire database.2. Journalizing facilities, which maintain an audit trail of transactions

and database changes.3. C heckpoint facility, by which the DBMS periodically suspends all

processing and synchronizes its files and journals.

Page 24: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 24/49

4. R ecovery manager, which allows the DBMS to restore the database toa correct condition and restart processing transactions.

Page 25: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 25/49

Introduction to the E-R Model An entity-relationship data model (or E- R Model) is a detailed, logical

representationof the data for an organizationor for a business area.- normally expressed as an entity-relationship diagram (or E- R

diagram)Entity a person, place, object, event, or concept in the user environment

about which the organization wishes to maintain data.Entity type (or entity class) is a collection of entities that share common

propertiesor characteristics.Entity instance (or instance) is a single occurrence of an entity type. Attribute a property or characteristic of an entity that is of interest to

the organization.C andidate key an attribute or combination of attributes that uniquely

identifies each instance of an entity type.

Page 26: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 26/49

Primary key a candidate key that has been selected as the identifier foran entity type.

Multi-valued attribute can have more than one value for each entity instance.

R elationship an association between the instance of one or more entity types that is of interest to the organization.Degree of a relationship the number of entity types that participate in

that relationship.a) U nary relationship also called a recursive relationship, is a

relationship between the instances of one entity type.b) Binary relationship a relationship between instances of two entity

types and is the most common type of relationship encountered indata modeling.

Page 27: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 27/49

c) Ternary relationship a simultaneous relationship among instancesof three entity types.

B ASIC SYMB OLS

ENTITY RELATIONSHIP PRIMARY KEY ATTRI BU TE

MU LTIVAL U ED ATTRI BU TE

Page 28: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 28/49

U NA R Y BINA R Y

TER NA R Y

Page 29: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 29/49

MANDATOR Y 1 C A R DINALITY

MANY (M) C A R DINALITY (1,2, ,MANY)

O PTIO NAL 0 OR 1 C A R DINALITY

O PTIO NAL ZERO -MANY C A R DINALITY (0,1,2, ,MANY)

Page 30: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 30/49

MAINTAINS CO NTAINS

STAFFS

PER FOR MS DIAGNO SES TR EATS

IS ASSIGNED

PER FOR MED FOR IS ASSIGNED TO

U SES

SU PPLIED BY

PRO VIDES

HO SPITAL

WA R DLABOR ATOR Y PHYSIC IAN

TEST PATIENTSTAFF

MEDIC AL/SUR GIC AL ITEM

VENDOR

SU PPLY ITEM

Page 31: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 31/49

Logical database model the process of transforming theconceptual data model into a logical database model.

Logical database model a design that conforms to the datamodel for a class of database management system.

Types of logical database models1. Hierarchical Model records are arranged in a top-down

structure that resembles an upside down tree.

Page 32: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 32/49

Example:DEPA R TMENT

EMPLO YEE PRO JEC T

EQU IPMENTDEPENDENTSKILL

Page 33: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 33/49

2. Network Model a data model in which each recordtype may be associated with an arbitrary number of different record types.

Page 34: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 34/49

Example:DEPA R TMENT

EMPLO YEE PRO JEC T

DEPENDENT EQU IPMENT

Page 35: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 35/49

3. R elational Model a data model that represents data in the form of tables or relations.

Example:DEPA R TMENT

DEPT. NO. NAME LOCATION

D100D200D300

ENGINEER ING A CCOU NTING

MA R KETING

WESTSOU TH

EAST

Page 36: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 36/49

Logical data model(normalized relations)

R epresent entities

R epresentrelationships

Normalize the

relations

Merge the relations

Conceptual datamodel

(E-R diagrams)

Page 37: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 37/49

A relation is a named, two-dimensional table of data. Each relationconsists of a set of named columns and an arbitrary number of unnamed rows.

(a) Table with repeating groups

EMPID NAME DEPT SALARY CO U RSE DATECOMPLETED

100 MargaretSimpson

Marketing 42,000 SPSS 6/ 19/9x

Surveys 10/7/9x

140 Alan Beeton Accounting 39,000 Tax Acc 12/8/9x

110 C hris Lucero Info Systems 4 1,500 SPSS 1/ 12/9x

C++

190 Lorenzo Davis Finance 38,000 Investments 5/7/9x150 Susan Martin Marketing 38,500 SPSS 6/ 19/9x

TO M 8/ 12/9x

Page 38: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 38/49

EMPLOYEE2

(b) EMPLO YEE2 relation

EMPID NAME DEPT SALARY CO U RSE DATECOMPLETED

100 MargaretSimpson

Marketing 42,000 SPSS 6/ 19/9x

100 MargaretSimpson

Marketing 42,000 Surveys 10/7/9x

140 Alan Beeton Accounting 39,000 Tax Acc 12/8/9x

110 C hris Lucero Info Systems 4 1,500 SPSS 1/ 12/9x

110 C hris Lucero Info Systems 4 1,500 C++ 4/22/9x

190 Lorenzo Davis Finance 38,000 Investments 5/7/9x150 Susan Martin Marketing 38,500 SPSS 6/ 19/9x

150 Susan Martin Marketing 38,500 T O M 8/ 12/9x

Page 39: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 39/49

Properties of Relations1. Entries in columns are atomic (or single-valued).2. Entries in columns are from the same domain.3. Each row is unique (no duplicate rows).

4. The sequence of columns (left to right) is insignificant.5. The sequence of rows (top to bottom) is insignificant.

Well-Structured Relation: A relation that contains a minimum amount of redundancy and allows users to

insert, modify, and delete the rows in a table without errors or inconsistencies. Anomalies: Errors or inconsistencies that may result when a user attempts to

update a table that contains redundant data.Three types of anomalies: insertion, deletion, and modification anomalies.

Page 40: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 40/49

Employee1

EMPID NAME DEPT SALARY

100 MargaretSimpson

Marketing 42,000

140 Alan Beeton Accounting 39,000

110 C hris Lucero Info. Systems 4 1,500

190 Lorenzo Davis Finance 38,500

150 Susan Martin Marketing 38,500

Page 41: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 41/49

Normalization: The process of decomposing relations with anomalies to produce smaller, well structuredrelations.

Normal form: A state of a relation that results from applying simple rules regarding dependencies to thatrelation.

Steps in normalization:

Table with repeatinggroups

First normal form

Second normal form

Third normal form

R emove repeating

groups

R emove transitivedependencies

R emove partialdependencies

Page 42: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 42/49

Boyce-C odd normalform

R emoveremaininganomalies

Fourth normal form

Fifth normal form

R emovemultivalued

dependencies

R emoveremaininganomalies

resulting fromfunctional

dependencies

Page 43: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 43/49

Functional dependency: A particular relationship between two attributes. For any relation R ,attribute B is functionally dependent on attribute A if, for every valid instance of A, that value of A uniquely determines the value of B. The functional dependence of B on A isrepresented as A--->B.

Example:

SSN NAME,ADDR

ESS,BIR

THDATE: A persons name, address, and birthdate arefunctionallydependent on that person s Social Security number.Determinant: The attribute on the left-hand side of the arrow in a functional dependency; A

is a determinant in the following functional dependency: A B.C omposite key: A primary key that contains more than one attribute.Example:

EMPLO YEE2(EMPID,NAME,DEPT,SALA R Y,COUR SE,DATE CO MPLETED).

Page 44: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 44/49

1. First normal form( 1NF): A relation that contains no repeating groups.HO SPITAL

TABLE WITH R EPEATING GROU PS

PATIENTNO

PATIENTNAME

PATIENT ADDR ESS

SUR G_ LIC _NO

SUR G.NAME

SUR GDATE

SUR GER Y DRU G ADMIN

SIDE EFFEC T

268300 WILLIAMS QC 35002500

PA R SO NCO DD

10/5/903/7/92

HEA R TEYES

AAA BBB

HEADA C HENA U SEA

543290 BAKER MAKATI 3500 PA R SO N 5/15/93 HEA R T AAA HEADA C HE

2600 MILLER 7/8/95 KIDNEY CCC NU MBNESS

2800 BENNETT 9/10/97 INTESTINE DDD BA C KA C HE

Page 45: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 45/49

HO SPITAL

R EPEATING GROU PS R EMO VED(1NF)THE R ELATIO N C AN ALSO BE R EPR ESENTED AS

HO SPITAL (PATIENT_N O .,PATIENT_NAME,PATIENT_ADD R ESS,SUR G_LIC _NO .,SUR G_DATE,SUR GER Y,DRU G_ADMIN.,SIDE_EFFEC T)

PATIENT NO PATIENTNAME

PATIENT ADDR ESS

SUR G_LIC _NO

SUR GNAME

SUR GDATE

SUR GER Y DRU G ADMIN

SIDE EFFEC T

268300268300543290543290543290

WILLIAMS WILLIAMS

BAKER BAKER

BAKER

QC

QC

MAKATIMAKATIMAKATI

35002500350026002800

PA R SO NCO DD

PA R SO NMILLER

BENNETT

10/5/903/7/925/15/937/8/959/ 10/97

HEA R TEYES

HEA R TKIDNEY

INTESTINE

AAA BBB

AAA CCC

DDD

HEADA C HENA U SEA

HEADA C HENU MBNESSBA C KA C HE

Page 46: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 46/49

Page 47: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 47/49

PAT_SUR GEO N

PAT_SUR GEO N (PATIENT_NO .,SUR G_LIC _NO .,SUR G_NAME,SUR G_DATE,SUR GER Y,DRU G_ADMIN,SIDE_EFFEC T)

SUR GEO N

SUR GEO N (SUR G_LIC _NO .,SUR G_NAME)

PATIENT_N O SUR G_LIC_NO

SUR GNAME

SUR GDATE

SUR GER Y DRU G ADMIN

SIDEEFFEC T

268300268300543290543290543290

35002500350026002800

PA R SO NCO DD

PA R SO NMILLER

BENNETT

10/5/903/7/925/15/937/8/959/ 10/97

HEA R TEYES

HEA R TKIDNEY

INTESTINE

AAA BBB

AAA CCC

DDD

HEADA C HE

NA U SEA HEADA C H

ENU MBNESSBA C KA C HE

SUR G_LIC _NO SUR G NAME

35002500350026002800

PA R SO NCO DD

PA R SO NMILLER

BENNETT

Page 48: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 48/49

3. Third normal form(3NF): A relation is in third normal form if it is in second normal form and no transitive dependenciesexist.

Transitive dependency:A functional dependencybetween two (or more) nonkey attributes in a relation.PATIENT

PATIENT (PATIENT_NO ,PATIENT_NAME,PATIENT_ADDR ESS)

SUR GEO N

SUR GEO N (SUR G_LIC _NO ,SUR G_NAME)

PATIENT NO PATIENTNAME

PATIENT ADDR ESS

268300543290

WILLIAMSBAKER

QC

MAKATI

SUR G_LIC _NO SUR G_NAME

3500

250026002800

PA R SO NCO DD

MILLER

BENNETT

Page 49: Database Management System Lecture

8/3/2019 Database Management System Lecture

http://slidepdf.com/reader/full/database-management-system-lecture 49/49

PAT_D RU G_SUR G

PAT_D RU G_SUR G (PATIENT_NO ,SUR G_LIC _NO , SUR G_NAME,SUR G_DATE,SUR GER Y,DRU G_ADMIN)

DRU G

DRU G (DRU G_ADMIN,SIDE_EFFEC T)

PATIENT_NO

SUR G_LIC _NO

SUR G NAME SUR GDATE

SUR GER Y DRU G ADMIN

268300268300543290543290543290

35002500350026002800

PA R SO NCO DD

PA R SO NMILLER

BENNETT

10/5/923/7/925/15/937/8/929/ 10/97

HEA R TEYES

HEA R TKIDNEY

INTESTINE

AAA BBB

AAA CCC

DDD

DRU G_ADMIN SIDE EFFEC T

AAA

BBBCCC

DDD

HEADA C HE

NA U

SEA NU MBNESSBA C KA C HE


Recommended