Ddd ms march 2011   final
Upcoming SlideShare
Loading in...5
×
 

Like this? Share it with your network

Share

Ddd ms march 2011 final

on

  • 1,038 views

 

Statistics

Views

Total Views
1,038
Views on SlideShare
1,038
Embed Views
0

Actions

Likes
1
Downloads
81
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Ddd ms march 2011 final Document Transcript

  • 1. 1 DATABASE DESIGN & DEVELOPMENT 13th MARCH 2011 MARKING SCHEMEThis Marking Scheme has been prepared as a guide only to markers. This is not a set of modelanswers, nor is the Marking Scheme exclusive, for there will frequently be alternative responseswhich will provide a valid answer. Unless a question specifies that an answer be produced in aparticular form, then an answer that is correct, factually or in practical terms, must be given theavailable marks.If there is doubt as to the correctness of an answer the relevant NCC Education materials andassociated module textbook should be the first authority. Throughout the question, please credit any valid alternative point. Notice to Markers Where markers award half marks in any part of a question they should ensure that the total mark recorded for a task is rounded up to a whole mark.
  • 2. ANSWER ANY FOUR QUESTIONSQUESTION 1 MarksThroughout the question, please credit any valid alternative point.a) Oldenburg Marine Events is a company that organises various different sorts of meetings such as conferences and cruises aboard ships. Until now they have kept their records on a card index system but have realised that it is time that they moved over to a fully computerised database system. They have employed you to carry out the initial database design for them based on the following information: Customers make bookings for particular events. An event is made up of a journey, which consists of various destinations. For example a Mediterranean Cruise would have a journey that included a start point at Barcelona, then stops at Nice, Naples, Corfu and then a final stop point at Venice. All these places count as destinations. Most customers are classified as people. But some people are representatives of organisations and a record should be kept of this. An organisation might have more than one representative. Bookings and Events are classified by type including ‘Conference’, ‘Pleasure Cruise’, ‘Convention’, ‘Dealer Incentive’ or ‘Other Meeting’. A Booking could be made for an event type and then fulfilled by an event. An event will take place on a particular ship (also known as a vessel). Certain ships are suitable for one or more particular types of event. i) Draw the Entity-Relationship diagram for the above scenario. 10 Page 2 of 12 Database Design and Development AM March 2011 20/01/2011 Final © NCC Education Ltd 2011
  • 3. Marks JOURNEY PORT OF CALL aka DESTINATION Could be M:N as a destination could appear in more than 1 journey EVENT VESSEL TYPE EVENT VESSEL TYPE This is the fulfilment of a booking by a particular event. The assumption here is that an event might be booked by many different BOOKING clients. But his could also be a 1:1 or VESSEL Booking and Event could be merged. EVENT TYPE PERSON ORGANISATION When a booking is made it is for an event type, e.g. ŌD ealer IncentiveÕ. Notes on above: ½ mark should be given for every entity identified. ½ mark should be given for every relationship successfully specified in terms of degree (Optionality is not specified here.) Reasonable variation should be allowed so long as normalisation is not violated. ii) Using sensible assumptions identify all the primary and foreign keys for this diagram 10 Every entity should have a primary key (1/2 mark each up to 5 marks) All FKs (many ends of relationships) should be successfully identified (1/2 mark each up to 5 marks) This should correspond to the candidate’s specific solution. Page 3 of 12Database Design and Development AM March 2011 20/01/2011 Final © NCC Education Ltd 2011
  • 4. Marksb) Using the Entity-Relationship diagram you have drawn as an example make a distinction between data 5 and information Data is a set of symbols stored in a system that are unprocessed. (1 mark for this or similar). Information is data that has been processed in some way to set it in a meaningful context (1 mark) Up to 3 marks for an example such as a BOOKING which would contain as data a number of foreign keys that would be meaningless unless processed in such as way as to present them with their associated descriptor fields such as EVENT TYPE description. Total 25 Marks Page 4 of 12 Database Design and Development AM March 2011 20/01/2011 Final © NCC Education Ltd 2011
  • 5. QUESTION 2 MarksThroughout the question, please credit any valid alternative point.In a Student Records System system, the following tables have been created using SQL DDL commands. 1) CREATE TABLE Student_Module ( ModuleNo varchar2 (4) not null, StudentNo varchar2 (4) not null, ModuleStartDate date, GradeAwarded number(6), PRIMARY KEY (ModuleNo, StudentNo), FOREIGN KEY (StudentNo) REFERENCES Student(StudentNo) FOREIGN KEY (ModuleNo) REFERENCES Module(ModuleNo) ); 2) CREATE TABLE Student ( StudentNo varchar2 (4) not null, StudentName varchar2(10), Address Varchar2(20), PRIMARY KEY (StudentNo) ); 3) CREATE TABLE Module ( ModuleNo varchar2 (4) not null, Module Name varchar2 (30) not null, CourseCode varchar2(4) not null, PRIMARY KEY (ModuleNo), FOREIGN KEY (CourseCode) REFERENCES Course (CourseCode)); 4) CREATE TABLE Course ( CourseCode varchar2 (4) not null, CourseName varchar2(30) not null, PRIMARY KEY (CourseCode));a) Give the correct sequence in which the DDL commands should be executed in order to avoid violation 4 of integrity constraints. 4 marks for correct sequence. Marks can also be given for partially correct answers. CREATE TABLE Course before CREATE TABLE Module CREATE TABLE Student and CREATE TABLE Module before CREATE TABLE StudentModule Page 5 of 12 Database Design and Development AM March 2011 20/01/2011 Final © NCC Education Ltd 2011
  • 6. Marksb) A user tried to execute the following commands in the given order to insert values into the 12 aforementioned tables. Find those commands that would result in the return of an error message. Explain your answer 1) INSERT INTO Course values (‘2345’, ‘BA(Hons) History’, 25); 2) INSERT INTO Course values (‘2344’, ‘BSc Computing’); 3) INSERT INTO Course values (‘2346’, ‘BSc Business’); 4) INSERT INTO Module values (‘1010’, 2344, ‘2344’); 5) INSERT INTO Module values (‘1005’, ‘C++ Programming’, ‘2344’); 6) INSERT INTO Module values (‘1005’, ‘Ancient Civilizations of Africa’,‘2354’); 7) INSERT INTO Module values (1005, ‘Interface Design’,‘2344’); 8) INSERT INTO Student values (‘5566’, ‘JONES’, ‘CROSS ROAD’); 9) INSERT INTO Student values (‘5667’, ‘JONES’, ‘RIVER LANE’); 10) INSERT INTO Student values (‘5667’, ‘SMITH’, ‘MILL LANE’); 11) INSERT INTO StudentModule values (‘1005’, ‘5566’, ’03-FEB-2004’, 20); 12) INSERT INTO StudentModule values (‘1007’, ‘5566’, ’04-FEB-2004’, 40); 1 mark for each error identification. 1 mark for each correct explanation 1) INSERT INTO Course values (‘2345’, ‘BA(Hons) History’, 25); ERROR Too many values 2) INSERT INTO Course values (‘2344’, ‘BSc Computing’); OK 3) INSERT INTO Course values (‘2346’, ‘BSc Business’); OK 4) INSERT INTO Module values (‘1010’, 2344, ‘2344’); ERROR Incorrect data type i.e. module name is a varchar2 not a number 5) INSERT INTO Module values (‘1005’, ‘C++ Programming’, ‘2344’); OK 6) INSERT INTO Module values (‘1006’, ‘Ancient Civilizations of Africa’,‘2354’); ERROR Foreign Key does not match Primary Key in target table (i.e. no such course code) 7) INSERT INTO Module values (1005, ‘Interface Design’,‘2344’); ERROR Incorrect data type i.e. module code is a varchar2 not a number. 8) INSERT INTO Student values (‘5566’, ‘JONES’, ‘CROSS ROAD’); OK 9) INSERT INTO Student values (‘5667’, ‘JONES’, ‘RIVER LANE’); OK 10) INSERT INTO Student values (‘5667’, ‘SMITH’, ‘MILL LANE’); ERROR Duplicate Value for Student ID 11) INSERT INTO StudentModule values (‘1005’, ‘5566’, ’03-FEB-2004’, 20); OK 12) INSERT INTO StudentModule values (‘1007’, ‘5566’, ’04-FEB-2004’, 40); ERROR Foreign Key does not match Primary Key in target table (i.e. there is no such module as ‘1007’)c) Some changes are required to the aforementioned tables that require you to write two modification 4 statements. First write the SQL code that will rename the ‘Module’ table to ‘UNIT’. Secondly write the SQL code to add a column named ‘Local Authority’ of type Varchar2 and length 30 to the Student table. ALTER TABLE Module RENAME TO UNIT (2 marks) ALTER TABLE STUDENT ADD Local_Authority Varchar2(30) (2 marks) Partial answers can be credited with some marks. Page 6 of 12 Database Design and Development AM March 2011 20/01/2011 Final © NCC Education Ltd 2011
  • 7. Marksd) As part of the implementation of the aforementioned tables different users will have access to different 5 sets of data. Explain how the concept of ‘user groups’ might be used to achieve this. Users can be grouped into groups or ‘roles’ (1 mark). These roles can have names defined for them (1 mark). A common profile can be assigned to such a role (1 mark). The profile would involved levels of access for example to different tables or rows in tables (1 mark for either of these) and type of access create, update, delete etc. (1 mark). Total 25 Marks Page 7 of 12 Database Design and Development AM March 2011 20/01/2011 Final © NCC Education Ltd 2011
  • 8. QUESTION 3 MarksThroughout the question, please credit any valid alternative point.a) Give an outline of the rules that define the Object Oriented (OO) features of the ODMG Standard. 16 Complex objects – it must be possible to build complex objects by applying constructors to basic objects. Object Identity – each object must have a unique ID independent of the values of its attributes Encapsulation – programmers only have access to objects through their defined interfaces Object Classes – the construct of an object must be supported. A schema will be a set of classes. Inheritance – of both methods and attributes must be supported. Dynamic binding – methods names must be bound to logic at run-time Complete DML – the data manipulation language should be a general purpose programming language Extensible data types – the user must be able to define and build new data types from pre-defined types. 1 mark should be given for identifying each of the above rules and 1 additional mark for an explanation.b) Define and give a short description of the TWO (2) object specification languages in the ODMG 4 Standard: the ODL and the OIF. ODL is the object definition language (1 mark). Used to define the object types. (1 mark) OIF is the object interchange format (1 mark). Used to dump the state of an object database to a set of files or load from a set of files into an object database (1 mark)c) This question relates to contemporary data types. Give short definitions for FIVE (5) types of complex data that have become more prevalent in recent 5 years. Images –graphics and photographic images Audio – various forms of sound data Video – various forms of moving image Semi-structured data – SGML, Document formats Spatial data – GIS, spatial relations and queries 1 mark for each of the above (up to 5 marks) Total 25 Marks Page 8 of 12 Database Design and Development AM March 2011 20/01/2011 Final © NCC Education Ltd 2011
  • 9. QUESTION 4 MarksThroughout the question, please credit any valid alternative point.a) Outline the scope of the tasks of Data Administration 10 The answer could take a number of approaches but could identify any of a number of core activities: (A holistic mark out of 10 should be given but as a guide ½ mark could be given for identifying any of the points below plus an additional ½ mark for description/definition) Consultancy – offering advice etc. on all aspects of an organisation’s meta-data Corporate awareness – circulating knowledge of what data exists; stressing the importance of data Corporate requirements – identifying data requirements for an organisation; strategic planning Data analysis – developing business models based on data; supplying data structure information for management information systems Data control – implementing standards for access and control; ensuring recovery procedures are in place Data security – ensuring both technical and procedural controls are in place Data definition – implementing standards for definition Data integrity – developing and implementing standards to ensure integrity Data dictionary management – promoting use of data dictionary and monitoring its use Data privacy – compliance with legislation such as Data Protection Act in UK or similar legislation in other countries Data Sharing – encouraging sharing of data across applications and promoting the idea of data independence Note that other taxonomies would be accepted so long as core activities are identified.b) Describe the different types of data dictionary 5 ½ mark for naming type. ½ mark for description /explanation. Up to 5 marks. Conceptual Data Dictionary - record meta-data at high level (such as is used along with an Entity Relationship model) Logical Data Dictionary – slightly lower level of abstraction than conceptual data dictionary. Records structure of data and requirements without specifying how these requirements will be me Physical data dictionary – used to records data structures within the database itself.c) What are the key data security issues and what are the computer-based measures that can be taken to 5 ensure data security? 1 mark each for identifying and defining the following points up to 5 marks. Implementing authorisation on the operating system the database runs on Implementing authorisation strategies such as grant privileges and group access via the DBMS Setting up views that restrict access in some way. Allocating these to groups Taking regular back-ups to whole or part of database Maintaining a log of all changes to database Encryption of sensitive data If the weight of the answer is given more to the security issues than solutions then pertinent points should be rewarded. Alternative valid points should be rewarded but focus should be on technological rather than procedural solutions.d) With regard to Distributed Data explain the following concepts: i) Fragmentation 3 Fragmentation is the splitting of data between different sites (1 mark). Fragmentation can be vertical (1 mark) or horizontal (1 mark) Page 9 of 12 Database Design and Development AM March 2011 20/01/2011 Final © NCC Education Ltd 2011
  • 10. Marks ii) Local Autonomy 2 The principle that the sites of a distributed database are autonomous to the maximum possible extent (2 marks) Total 25 Marks Page 10 of 12Database Design and Development AM March 2011 20/01/2011 Final © NCC Education Ltd 2011
  • 11. QUESTION 5 MarksThroughout the question, please credit any valid alternative point.a) With regard to Normalisation explain with examples the following concepts: i) Functional Dependency 3 Two items, A and B, are said to be in a functionally determinant or dependent relationship if the same value of data-item B always appears with the same value of data-item A. (Up to 1.5 marks for definition plus up to 1.5 marks for an example). ii) First Normal Form 3 A relation is in first normal form if and only if every non-key attribute is functionally dependent on the primary key. (Up to 1.5 marks for definition plus up to 1.5 marks for an example). iii) Second Normal Form 3 A relation is in second normal form if and only if it is in first normal form and every non-key attribute is fully functionally dependent on the primary key. This could be stated as there being no partial key dependencies. (Up to 1.5 marks for definition plus up to 1.5 marks for an example). iv) Third Normal Form 3 A relation is in third normal form if and only if it is in second normal form and there are no non-key dependencies. This could also be stated as being in a state of being fully normalised. (Up to 1.5 marks for definition plus up to 1.5 marks for an example).b) Consider the following relation. Anomalies will still arise when someone tries to update this relation. 8 Identify and discuss ONE (1) insertion anomaly and ONE (1) deletion anomaly. Student ID Activity Fee 9901 Skiing 200 9902 Swimming 50 9922 Squash 50 9811 Swimming 50 Insertion. The schema contains data about both activities and who is doing those activities. We will not be able to store information about a new activity until someone is doing that activity. Up to 4 marks for this or similar Deletion. If someone stops doing an activity we not only lose data about them doing the activity but also the data about the activity itself e.g. how much it costs. Up to 4 marks for this or similarc) This question relates to Data Warehouses. 5 Identify and define the FOUR (4) key features of a data warehouse. 1 mark for each definition plus 1 mark for overall correct answer. Subject-Oriented – structured in terms of major subject areas Integrated – integrates data from different sources Time-variant – time is explicitly associated with data Non-volatile – not updated in real-time. Total 25 Marks Page 11 of 12 Database Design and Development AM March 2011 20/01/2011 Final © NCC Education Ltd 2011
  • 12. 12Learning Outcomes MatrixLearning materials refers to the standard course text: Database Systems by Paul Benyon-Davies 3rdedition, Palgrave-MacMillian, Basingstoke 2004 LO1 LO2 LO3 LO4 LO5 LO6 LO7 Learning Materials Reference1 a) 10 Chapter 16b) 10 Chapter 16c) 5 Chapter 22 a) 4 Chapter 11b) 12 Chapter 11/12c) 4 Chapter 11d) 5 Chapter 263 a) 16 Chapter 32b) 4 Chapter 32c) 5 Chapter 394 a) 10 Chapter 22b) 5 Chapter 22c) 5 Chapter 22d) 5 Chapter 375 a) 12 Chapter 18b) 8 Chapter 18c) 5 Chapter 40Total 65 40 20