Sei sulla pagina 1di 2

Chapter 2: Database System Concepts and Architecture

CHAPTER 2: DATABASE SYSTEM CONCEPTS AND ARCHITECTURE


Answers to Selected Exercises 2 !2 - Think of different users for the database of Figure 1.2. hat type of app!ications "ou!d each user need# To "hich user category "ou!d each be!ong and "hat type of interface "ou!d they need# Answer: $a% &egistration 'ffice (ser: They can enter data that ref!ect the registration of students in sections of courses) and !ater enter the grades of the students. App!ications can inc!ude: - &egister a student in a section of a course - Check "hether a student "ho is registered in a course has the appropriate prere*uisite courses - Drop a student from a section of a course - Add a student to a section of a course - +nter the student grades for a section App!ication programmers can "rite a number of canned transactions for the registration office end-users) pro,iding them "ith either forms and menus) or "ith a parametric interface. $b% Admissions 'ffice (ser: The main app!ication is to enter ne"!y accepted students into the database. Can use the same type of interfaces as $a%. $c% Transcripts 'ffice (ser: The main app!ication is to print student transcripts. App!ication programmers can "rite a canned transaction using a report generator uti!ity to print the transcript of a student in a prescribed format. The particu!ar student can be identified by name or socia! security number. Another app!ication "ou!d be to generate grade s!ips at the end of each semester for a!! students "ho ha,e comp!eted courses during that semester. Again) this app!ication cou!d be programmed using a report generator uti!ity. 2 !" - -o so!ution pro,ided. 2 !# - if you "ere designing a eb-based system to make air!ine reser,ations and to se!! air!ine tickets) "hich D./S Architecture "ou!d you choose from Section 2.0# hy# hy "ou!d the other architectures not be a good choice# Answer: 2.0.1 Three-Tier C!ient2Ser,er Architecture for eb App!ication is the best choice. The C!ient consists of eb (ser 3nterface. The eb Ser,er contains the app!ication !ogic "hich inc!udes a!! the ru!es and regu!ations re!ated to the reser,ation process and the issue of tickets4 the Database Ser,er contains the D./S. 2.0.1 Centra!i5ed D./S Architecture "ou!d not "ork since the user interface and database ser,er are on different machines for a "eb-based system. 2.0.2 .asic C!ient2Ser,er Architecture and 2.0.6 T"o-Tier C!ient2Ser,er Architecture "ou!d "ork if the .usiness 7ogic can reside on ser,er other than the D./S Ser,er. 3n genera!) if the business !ogic "as on the D./S Ser,er) it "i!! put an e8cessi,e burden on the ser,er. 3f the business !ogic "ere to reside on the "eb c!ient) it "i!! burden the communication net"ork as "e!! a possib!y thin c!ient.
Copyright 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley.

Chapter 2: Database System Concepts and Architecture

2 !$ - Consider Figure 2.1. 3n addition to constraints re!ating the ,a!ues of co!umns in one tab!e to co!umns in another tab!e) there are a!so constraints that impose restrictions on ,a!ues in a co!umn or a combination of co!umns "ithin a tab!e. 'ne such constraint forces that a co!umn or a group of co!umns must be uni*ue across a!! ro"s in the tab!e. For e8amp!e) in the ST(D+-T tab!e) the Student-umber co!umn must be uni*ue $to pre,ent t"o different students from ha,ing the same Student-umber%. 3dentify the co!umn or the group of co!umns in the other tab!es that must be uni*ue across a!! ro"s in the tab!e# Answer: Tab!e C'(&S+

;&+&+<(3S3T+ S+CT3'-

?&AD+@&+;'&T

Co!umn$s% Course-umber Since this contains the combination of the department and the number that must be uni*ue "ithin the department. -ote "e "i!! o,er!ook the fact this does not accommodate a department from offering se,era! 9Specia! Topics: course "ith the same Course-umber but different tit!es. e cou!d make this a combination of Course-umber and Course-ame) but this is more succeptib!e to someone mistyping "hi!e entering data. The combination of Course-umber and ;rere*uisite-umber Section3dentifier e assume that no t"o sections can ha,e the same Section3dentifier. 3f "e "ere to consider that Section3dentifier is uni*ue on!y "ithin a gi,en course offered in a gi,en term $such as section 2 of CS1=1% then the ans"er changes to the combination of Section3dentifier) Course-umber) Semester) and >ear. Student-umber and Section3dentifier As per assumption stated in S+CT3'-) the Section3dentifier "i!! be different if a student takes the same course or a different course in another term.

Copyright 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley.

Potrebbero piacerti anche