Result: empty because no tuples satisfy the result. Also show the result of each query as it would apply to the database state of Figure 3. Answers: In the relational algebra, as in other languages, it is possible to specify the same query in multiple ways. We give one possible solution for each query. Referential integrity constraints are shown as directed arcs in Figure 6.
|Published (Last):||25 June 2013|
|PDF File Size:||5.89 Mb|
|ePub File Size:||17.68 Mb|
|Price:||Free* [*Free Regsitration Required]|
Answer: a Query List the names of all students majoring in Computer Science. Answer: Redundancy is when the same fact is stored multiple times in several places in a database. For example, in Figure 1. If the DBMS has no control over this, we have uncontrolled redundancy. What type of applications would each user need? To which user category would each belong and what type of interface would they need? Answer: a Registration Office User: They can enter data that reflect the registration of students in sections of courses, and later enter the grades of the students.
Applications can include: - Register a student in a section of a course - Check whether a student who is registered in a course has the appropriate prerequisite courses - Drop a student from a section of a course - Add a student to a section of a course - Enter the student grades for a section Application programmers can write a number of canned transactions for the registration office end-users, providing them with either forms and menus, or with a parametric interface.
Can use the same type of interfaces as a. Application programmers can write a canned transaction using a report generator utility to print the transcript of a student in a prescribed format. The particular student can be identified by name or social security number. Another application would be to generate grade slips at the end of each semester for all students who have completed courses during that semester. Again, this application could be programmed using a report generator utility.
Why would the other architectures not be a good choice? Answer: 2. The Client consists of Web User Interface. The Web Server contains the application logic which includes all the rules and regulations related to the reservation process and the issue of tickets; the Database Server contains the DBMS.
In general, if the business logic was on the DBMS Server, it will put an excessive burden on the server. If the business logic were to reside on the web client, it will burden the communication network as well a possibly thin client.
One such constraint forces that a column or a group of columns must be unique across all rows in the table. Identify the column or the group of columns in the other tables that must be unique across all rows in the table? We could make this a combination of CourseNumber and CourseName, but this is more succeptible to someone mistyping while entering data.
If we were to consider that SectionIdentifier is unique only within a given course offered in a given term such as section 2 of CS then the answer changes to the combination of SectionIdentifier, CourseNumber, Semester, and Year.
This is similar but not identical to the database shown in Figure 1. Both social security number and student number have unique values for each student. Both name and code have unique values for each department. The value of course number is unique for each course. Design an ER schema for this application, and draw an ER diagram for that schema. Specify key attributes of each entity type and structural constraints on each relationship type. Note any unspecified requirements, and make appropriate assumptions to make the specification complete.
Such an attribute will have one entry for each college previously attended, and this entry is composed of: college name, start and end dates, degree entries degrees awarded at that college, if any , and transcript entries courses completed at that college, if any. Each degree entry is formed of degree name and the month and year it was awarded, and each transcript entry is formed of a course name, semester, year, and grade.
Design an attribute to hold this information. Use the conventions of Figure 7. Answer: This example illustrates a perceived weakness of the ER model, which is: how does the database designer decide what to model as an entity type and what to model as a relationship type.
Other ER schema designs are also possible for this problem. Extract from the ER diagram the requirements and constraints that resulted in this schema.
Try to be as precise as possible in your requirements and constraints specification. House of Representatives. A team has a number of players, not all of whom participate in each game. It is desired to keep track of the players participating in each game for each team, the positions they played in that game, and the result of the game. Try to design an ER schema diagram for this application, stating any assumptions you make. Choose your favorite sport soccer, football, baseball Answer: The following design may be used for a baseball league.
Here, we assumed that each game in the schedule is identified by a unique Game , and a game is also identified uniquely by the combination of Date, starting Time, and Field where it is played.
This attribute can be designed to keep the information needed for statistics, and may be quite complex. One possible design for the Performance attribute may be the following using the notation of Figure 7. Hitting has a value for each AtBat of a player, and records the HitType suitable coded; for example, 1 for single, 2 for double, 3 for triple, 4 for home run, 0 for walk, -1 for strikeout, -2 for fly out, Pitching has a value for each inning during which the player pitched.
Defense has a value for each inning a player played a fielding position. We can have a less detailed or a more detailed design for the performance of a player in each game, depending on how much information we need to keep in the database. Suitable variations of the ER diagram shown below can be used for other sports.
Each bank can have multiple branches, and each branch can have multiple accounts and loans. If so, give its name, its partial key, and its identifying relationship. Justify your choices. How does this show up on the min,max constraints? Partial key: BranchNo.
Download: Fundamentals Of Database Systems Solutions.pdf
Download: Solution Manual Fundamentals Of Database Systems - Ramez Elmasri.pdf
Download: Fundamentals Of Database Systems Solution Manual 6th Edition.pdf