SlideShare ist ein Scribd-Unternehmen logo
1 von 19
Downloaden Sie, um offline zu lesen
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 2 of 20
SECTION A
OBJECTIVE QUESTIONS (50 marks)
INSTRUCTION:
This section consists of FORTY (40) objective questions. Answer ALL questions in the
answer booklet.
1. “A software system that enable user to define, create and maintain the database”.
This statement describes [CLO 1]
A. Oracle 10g
B. Microsoft Office Access 2007
C. Database Management System
D. Data warehouse
2. The function of a database is to ____________. [CLO 1]
A. collect and organize input data
B. check all input data
C. check all spelling
D. output data
3. Choose the software that is commonly used in database. [CLO 1]
A. Oracle
B. SQL Access
C. SQL desktop
D. Linux
4. Internal Schema is one of the three-schema architecture. Which one is true about
Internal Schema? [CLO 1]
A. It hides the details of physical storage structures and concentrates on
describing entities, data types, relationships, user operations, and constraints.
B. Uses a physical data model and describes the complete details of data storage
and access paths for the database.
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 3 of 20
C. Implementation of data model
D. The part of the database that a particular user is interested in and hides the rest
of the database from user
5. A _____________ is the set of allowable values for one or more attributes.
[CLO 1]
A.Cardinality
B.Tuple
C.Degree
D.Domain
6. Within a table, the primary key must be unique so that it will identify each row. When
this is the case, the table is said to exhibit ________ integrity.
[CLO 1]
A. Referential
B. Entity
C. Enforced
D. Key
7. The data type of values that appear in each column is represented by
_________________ of possible values. [CLO 1]
A. Range
B. Product
C. Domain
D. Function
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 4 of 20
8. Based on Figure 1, identify which one is the Candidate Key?
Figure 1 [CLO 1]
A. W
B. X
C. Y
D. Z
9. All companies operate four departments in their organization. This relationship
represents a _______________. [CLO 1]
A. one-to-one relationship.
B. one-to-many relationship.
C. many-to-one relationship.
D. many-to-many relationship.
10. __________________works on a single relation R and defines a relation that
constrains only those tuples (rows) of R that satisfy the specified condition
(predicate). [CLO 1]
A. Cartesian product
B. Difference
C. Selection
D. Intersection
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 5 of 20
11. _________________ works on a single relation R and defines a relation that contains
a vertical subset of R, extracting the values of specified attributes and eliminating
duplicates. [CLO 1]
A. Projection
B. Cartesian Product
C. Difference
D. Intersection
12. The ______________set operator combines all tuples from two relations excluding
duplicates. [CLO 1]
A. Union
B. Intersect
C. Difference
D. Divide
13. The ___________ operator returns all tuples in one relation that are not found in other
relation. [CLO 1]
A. Intersect
B. Product
C. Select
D. Difference
14. What is meant by the term union compatibility? [CLO 1]
A. When two or more tables share the same number of columns
B. When two or more tables have the same degree
C. When two or more tables share the same domains
D. When two or more tables share the same number of columns and when they share
the same domain
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 6 of 20
15. What is meant by the following relational algebra statement?
STUDENT x COURSE [CLO 1]
A. Compute the natural join between the STUDENT and COURSE relations.
B. Compute the left outer join between the STUDENT and COURSE relations.
C. Compute the Cross Product between the STUDENT and COURSE relations.
D. Compute the outer join between the STUDENT and COURSE relations.
Question 16,17 and 18 are based on Figure 2 :
Figure 2
16. A relational algebra operator applied to tables of EMPLOYEES and DEPARTMENT
produces the following result as in Table 1
Table 1
The operator is: [CLO 3]
A. An outer join operator
B. The project operator
C. The cross product operator
D. The natural join operator
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 7 of 20
17. A relational algebra operator applied to tables of EMPLOYEES and DEPARTMENT
produces the following result as in Table 2
Table 2
The operator is: [CLO 3]
A. An outer join operator
B. The project operator
C. The cross product operator
D. The natural join operator
18. A relational algebra operator applied to tables of EMPLOYEES and DEPARTMENT
produces the following result as in Table 3
Table 3
The operator is: [CLO 3]
A. An outer join operator
B. The project operator
C. The cross product operator
D. The natural join operator
19. Which clause would you use in a SELECT statement to limit the display to those
employees whose salary is greater than 5000? [CLO 3]
A. WHERE SALARY > 5000
B. HAVING SALARY > 5000
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 8 of 20
C. ORDER BY SALARY > 5000
D. GROUP BY SALARY > 5000
20.
You use this SQL statement to retrieve data from a table for ______________.
[CLO 1]
A. Viewing
B. Deleting
C. Inserting
D. Updating
21. Which are Data Manipulation Language (DML) statements?
i. SELECT
ii. ALTER
iii. DROP
iv. DELETE
[CLO 1]
A. i, iv
B. ii, iii
C. i, ii, iii
D. ii, iii, iv
22. What happens if the WHERE clause is omitted from a DELETE statement?
[CLO 1]
A. All records from the table are deleted
B. No record from the table will be deleted
C. First record of the table will be deleted
D. The statement will not be executed and will give a syntax error
SELECT *
FROM orders;
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 9 of 20
23. You need to produce a report for mailing labels for all customers. The mailing label
must have only the customer name and address. The CUSTOMERS table has these
columns:
CUST_ID NUMBER(4) NOT NULL
CUST_NAME VARCHAR2(100) NOT NULL
CUST_ADDRESS VARCHAR2(150)
CUST_PHONE VARCHAR2(20)
Which SELECT statement accomplishes this task? [CLO3]
A. SELECT *FROM CUSTOMERS;
B. SELECT CUST_NAME, CUST_ADDRESS, CUST_PHONE
FROM CUSTOMERS;
C. SELECT CUST_ID,CUST_NAME,CUST_ADDRESS, CUST_PHONE
FROM CUSTOMERS;
D. SELECT CUST_NAME, CUST_ADDRESS
FROM CUSTOMERS;
24. Which INSERT statement is correct to insert a new row into table of employees?
A. INSERT INTO employees (employee_id) VALUES (1000);
B. INSERT INTO employees VALUES (NULL, ‘John’,
‘Smith’);
C. INSERT INTO employees (first_name, last_name) VALUES
(‘John’, ‘Smith’);
D. INSERT INTO employees (first_name, last_name,
employee_id) VALUES (100, ‘John’, ‘Smith’);
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 10 of 20
25. How to select all the records from a table named ‘Persons’ where the value of the
column “FirstName” starts with an “a” using SQL statement? [CLO 3]
A. SELECT * FROM Persons WHERE FirstName LIKE ‘%a’;
B. SELECT * FROM Persons WHERE FirstName= ‘a’;
C. SELECT * FROM Persons WHERE FirstName LIKE ‘a%’;
D. SELECT * FROM Persons WHERE FirstName LIKE ‘%a%’;
26. In UPDATE statement, choose the correct answer to update firstname = Mary to
firstname = Marry from a table named "staff". [CLO 3]
A. UPDATE RECORD staff SET FName = 'Marry' WHERE LName = 'Mary';
B. UPDATE staff SET FName = 'Marry' WHERE LName = 'Mary';
C. UPDATE staff SET INTO FName = 'Marry' WHERE LName = 'Mary';
D. UPDATE RECORD staff SET INTO FName = 'Marry' WHERE LName = 'Mary';
27. A goal of normalization is to minimize _____________. [CLO 1]
A. the number of relationships
B. the number of entities
C. the number of tables
D. data redundancy
28. A table that satisfies 2NF ___________________. [CLO 1]
A. always satisfies 1NF
B. may violate 1NF
C. always satisfies 3NF
D. always satisfies BCNF
29. On an entity-relationship diagram, a diamond represents a ___________.
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 11 of 20
[CLO 1]
A. multivalued attribute
B. data flow
C. entity
D. relationship
30. A person, place, object, event, or concept in the user environment about which the
organization wishes to maintain data refers to a(n): ___________________ .
[CLO 1]
A. Cardinality
B. Attribute
C. Relationship
D. Entity
31. When applying the optional 1-M relationship rule for converting an ERD into a
relational table design, which of the following statements is true? [CLO1]
A. Each 1-M relationship with 0 for the minimum cardinality on the parent side
becomes a new table.
B. The primary key of the new table is the primary key of the entity type on the child
(many) side of the relationship.
C. The new table contains foreign keys for the primary keys of both entity types
participating in the relationship.
D. Both foreign keys in the new table do not permit null values.
32. What type of relationship is expressed with the phrase "Student takes Class"?
[CLO 1]
A. 1 : M
B. M : 1
C. 1 : 1
D.M : N
33. When applying the M-N relationship rule for converting an ERD into a relational
table design, which of the following statements is true?
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 12 of 20
i. Each M-N relationship becomes a separate table
ii. The foreign keys must not allow null values.
iii. The primary key of the table is a combined key consisting of the
primary keys of the entity types participating in the M-N relationship.
iv. The primary key of the table is the primary key of the entity type
participating in the M-N relationship which has the most attributes.
[CLO 1]
A. i,ii
B. i,iii
C. i,ii,iii
D. ii,iii,iv
34. Based on Figure 3 the BOOKS and MEMBER entities are related to each other. The
relationship on the MEMBER side indicates that:
Figure 3
[CLO 1]
A. A BOOKS may be borrowed by one or more MEMBER.
B. A MEMBER may borrow one BOOKS.
C. A BOOKS may be borrowed by zero or one MEMBER only.
D. A MEMBER may borrow zero or more BOOKS.
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 13 of 20
35. Choose the correct Entity Relationship Model diagram based on the situation given.
“Each INSTRUCTOR may teach one or more CLASS”
“Each CLASS is taught by one INSTRUCTOR”
[CLO 1]
A.
B.
C. .
D.
36. ______________ refers to the requirement that other operations cannot access data that has
been modified during a transaction that has not yet been completed.
[CLO 2]
A. Consistent
B. Isolated
C. Durable
D. Atomic
C INSTRUCTOR CLASS
teach
1 1
((0, N) (1,1)
C INSTRUCTOR CLASS
teach
(1,N) (1,1)
1 M
C INSTRUCTOR CLASS
teach
(0,1) (1,1)
1 1
C INSTRUCTOR CLASS
teach
(0,N) (1,1)
1 M
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 14 of 20
37. _____________is the ability of the DBMS to recover the committed transaction updates
against any kind of system failure. [CLO 2]
A. Consistent
B. Isolated
C. Durable
D. Atomic
38. Deadlocks are possible only when one of the transactions wants to obtain a (n)
_________________ lock on a data item. [CLO 2]
A. Binary
B. Exclusive
C. Shared
D. Complete
39. Which of the following term below refers to the statement stated below?
[CLO 2]
A. Consistent
B. Durable
C. Atomic
D. Isolated
 All of the tasks of a database transaction must be completed
 If incomplete due to any possible reasons, the database transaction
must be aborted.
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 15 of 20
40. If locking is not available and several users access a database concurrently, problems
may occur if their transactions use the same data at the same time. Concurrency
problems include
i. Lost or buried updates.
ii. Uncommitted dependency
iii. Inconsistent analysis
iv. Transaction Log
[CLO 2]
A. i
B. ii,iii
C. i,ii,iii
D. i,iii,iv
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 16 of 20
SECTION B
STRUCTURED QUESTIONS (50 marks)
INSTRUCTION:
This section consists of TWO (2) structured questions. Answer ALL questions.
QUESTION 1
a) ANSI-SPARC Architecture, is an abstract design standard for a Database
Management System (DBMS), first proposed in 1975. Given ANSI-
SPARC architecture in Figure 1.1, explain each level.
Figure 1.1
[CLO 1]
(3 marks)
b) Database is a collection of persistent data that can be shared and
interrelated.
i. Explain TWO (2) properties of database.
ii. Explain TWO (2) features of Database Management System.
[CLO 1]
(4 marks)
[CLO 1]
(2 marks)
c) Illustrate THREE (3) most common relationships in E-R models. [CLO 1]
(3 marks)
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 17 of 20
STUDENT
STU_NUM STU_LNAME
321452 Bowser
324257 Smithson
ENROLL
CLASS_CODE STU_NUM ENROLL_GRADE
10014 321452 C
10014 324257 B
10018 321452 A
10018 324257 B
10021 321452 C
10021 324257 C
CLASS
CLASS_CODE CRS_CODE CLASS_SECTION CLASS_TIME CLASS_ROOM PROF_NUM
10014 ACCT-211 3 THUR, 2:30- 3.45PM BUS252 342
10018 CIT-220 2 MON, 9:00- 9:50PM KLR211 114
10021 QM-261 1 WED, 8:00- 8:50AM KLR200 114
d) Study the tables STUDENT, ENROLL and CLASS in Figure 1.2:
Figure 1.2
i. Determine primary key for each table
ii. Determine foreign keys for these tables
iii. Write suitable command to create a new table consisting of
class code, student number, class room and class time
[CLO 3]
(2 marks)
[CLO 3]
(2 marks)
[CLO3]
(4 marks)
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 18 of 20
e) Draw the ER Diagram for relational schemes in Figure 1.3:
PRODUCT ( product_code, product_name, price, brand)
BUYS ( recipt_no, product_code, quantity, discount, sub_total)
RECIPT ( receipt_no, date, customer_no)
CUSTOMER ( customer_no, name, address, phone_no)
Figure 1.3
[CLO 3]
(5 marks)
QUESTION 2
a) i) Explain TWO (2) properties of database transaction.
ii) Explain TWO (2) types of recovery tools.
[CLO 1]
(4 marks)
[CLO 2]
(2 marks)
b) Identify THREE (3) DDL statements in SQL and the function of each
statement.
[CLO 1]
(3 marks)
c) Describe the terms below:
i. Normalization
ii. Second Normal Form (2NF)
iii. Third Normal Form (3NF)
[CLO 1]
(3 marks)
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 19 of 20
d) Generate the output for the following SQL statements based on
Table 2.1.
Table 2.1
i. SELECT vehicleID, platNo, yearProduce, model
FROM vehicle
WHERE yearProduce >= 2000
ORDER BY yearProduce asc
ii. SELECT vehicleID, platNo, model
FROM vehicle
WHERE model LIKE “Perodua%”
iii. SELECT vehicleID, platNo, yearProduce
FROM vehicle
WHERE price < 20000
iv. SELECT SUM(price)
FROM vehicle
[CLO 3]
(2 marks)
(2 marks)
(2 marks)
(2 marks)
CONFIDENTIAL FP304 DATABASE SYSTEM
Page 20 of 20
e) Table 2.2 shows a list of patient appointments with the doctor. Each
patient is given the time and date of appointment with doctors in a particular
room. Show the steps on how you make the process of normalization stage 1NF,
2NF and 3NF.
Appointment
[CLO 3]
(5 marks)
Table 2.2
NoBilik
Tarikh Masa
AT020123 Kamal 1/12/2002 10.00 S15
AT00111 Jamaliah 1/12/2002 12.00 S15
CT00456 Sudin 1/12/2002 10.00 S10
CT00456 Sudin 14/1/2002 14.00 S10
AT00111 Jamaliah 14/1/2002 16.30 S15
AT00103 Abu 15/1/2002 18.00 S13
NamaPesakit
Temujanji
8765 Shamsul
8602 Maizul
8111 Aziz
Staff# Nama_Doktor Pesakit#

Weitere ähnliche Inhalte

Was ist angesagt?

Chapter 9 security privacy csc
Chapter 9 security privacy cscChapter 9 security privacy csc
Chapter 9 security privacy csc
Hisyam Rosly
 
3 Tier Architecture
3  Tier Architecture3  Tier Architecture
3 Tier Architecture
Webx
 
E-Commerce & Kedai Online
E-Commerce & Kedai OnlineE-Commerce & Kedai Online
E-Commerce & Kedai Online
Home
 
FINAL PAPER FP501 OPEN SOURCE OPERATING SYSTEM
FINAL PAPER FP501 OPEN SOURCE OPERATING SYSTEMFINAL PAPER FP501 OPEN SOURCE OPERATING SYSTEM
FINAL PAPER FP501 OPEN SOURCE OPERATING SYSTEM
Amira Dolce Farhana
 
5 maksud dan jenis perisian
5 maksud dan jenis perisian5 maksud dan jenis perisian
5 maksud dan jenis perisian
wazi musa
 
FINAL PAPER FP301 OBJECT ORIENTED PROGRAMMING
FINAL PAPER FP301 OBJECT ORIENTED PROGRAMMINGFINAL PAPER FP301 OBJECT ORIENTED PROGRAMMING
FINAL PAPER FP301 OBJECT ORIENTED PROGRAMMING
Amira Dolce Farhana
 

Was ist angesagt? (20)

Database normalization
Database normalizationDatabase normalization
Database normalization
 
Chapter 9 security privacy csc
Chapter 9 security privacy cscChapter 9 security privacy csc
Chapter 9 security privacy csc
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
KELEMAHAN MENYIMPAN MAKLUMAT DALAM BENTUK PANGKALAN DATA
KELEMAHAN MENYIMPAN MAKLUMAT DALAM BENTUK PANGKALAN DATAKELEMAHAN MENYIMPAN MAKLUMAT DALAM BENTUK PANGKALAN DATA
KELEMAHAN MENYIMPAN MAKLUMAT DALAM BENTUK PANGKALAN DATA
 
Database design & Normalization (1NF, 2NF, 3NF)
Database design & Normalization (1NF, 2NF, 3NF)Database design & Normalization (1NF, 2NF, 3NF)
Database design & Normalization (1NF, 2NF, 3NF)
 
Lengkap Microsoft Access Langkah Demi Langkah
Lengkap Microsoft Access Langkah Demi LangkahLengkap Microsoft Access Langkah Demi Langkah
Lengkap Microsoft Access Langkah Demi Langkah
 
3 Tier Architecture
3  Tier Architecture3  Tier Architecture
3 Tier Architecture
 
E-Commerce & Kedai Online
E-Commerce & Kedai OnlineE-Commerce & Kedai Online
E-Commerce & Kedai Online
 
Topologi rangkaian
Topologi rangkaianTopologi rangkaian
Topologi rangkaian
 
KONSEP PANGKALAN DATA (DBMS)
KONSEP PANGKALAN DATA (DBMS)KONSEP PANGKALAN DATA (DBMS)
KONSEP PANGKALAN DATA (DBMS)
 
Borang kerosakan komputer
Borang kerosakan komputerBorang kerosakan komputer
Borang kerosakan komputer
 
FINAL PAPER FP501 OPEN SOURCE OPERATING SYSTEM
FINAL PAPER FP501 OPEN SOURCE OPERATING SYSTEMFINAL PAPER FP501 OPEN SOURCE OPERATING SYSTEM
FINAL PAPER FP501 OPEN SOURCE OPERATING SYSTEM
 
5 maksud dan jenis perisian
5 maksud dan jenis perisian5 maksud dan jenis perisian
5 maksud dan jenis perisian
 
Normalization
NormalizationNormalization
Normalization
 
FINAL PAPER FP301 OBJECT ORIENTED PROGRAMMING
FINAL PAPER FP301 OBJECT ORIENTED PROGRAMMINGFINAL PAPER FP301 OBJECT ORIENTED PROGRAMMING
FINAL PAPER FP301 OBJECT ORIENTED PROGRAMMING
 
Bab 1 | PENGENALAN KEPADA PANGKALAN DATA
Bab 1 | PENGENALAN KEPADA PANGKALAN DATABab 1 | PENGENALAN KEPADA PANGKALAN DATA
Bab 1 | PENGENALAN KEPADA PANGKALAN DATA
 
Kumpulan 1: Jenis-jenis Pelayan dan Pelayan OS
Kumpulan 1: Jenis-jenis Pelayan dan Pelayan OSKumpulan 1: Jenis-jenis Pelayan dan Pelayan OS
Kumpulan 1: Jenis-jenis Pelayan dan Pelayan OS
 
Normalization in databases
Normalization in databasesNormalization in databases
Normalization in databases
 
Pengenalan kepada perisian
Pengenalan kepada perisianPengenalan kepada perisian
Pengenalan kepada perisian
 
Keselamatan pemasangan komputer
Keselamatan pemasangan komputerKeselamatan pemasangan komputer
Keselamatan pemasangan komputer
 

Andere mochten auch

Database Q&A
Database  Q&ADatabase  Q&A
Database Q&A
eduafo
 
Previous question papers of Database Management System (DBMS) By SHABEEB
Previous question papers of Database Management System (DBMS) By SHABEEBPrevious question papers of Database Management System (DBMS) By SHABEEB
Previous question papers of Database Management System (DBMS) By SHABEEB
Shabeeb Shabi
 
DATABASE Fp304 chapter 1
DATABASE Fp304   chapter 1DATABASE Fp304   chapter 1
DATABASE Fp304 chapter 1
Radio Deejay
 
Tcc apresentacao redes wi-fi
Tcc apresentacao redes wi-fiTcc apresentacao redes wi-fi
Tcc apresentacao redes wi-fi
Kelve Aragão
 
Computer Math Day 03 Addition
Computer Math Day 03 AdditionComputer Math Day 03 Addition
Computer Math Day 03 Addition
A Jorge Garcia
 
2009 Punjab Technical University B.C.A Database Management System Question paper
2009 Punjab Technical University B.C.A Database Management System Question paper2009 Punjab Technical University B.C.A Database Management System Question paper
2009 Punjab Technical University B.C.A Database Management System Question paper
Monica Sabharwal
 

Andere mochten auch (20)

Fundamentals of Database Systems Questions and Answers
Fundamentals of Database Systems Questions and AnswersFundamentals of Database Systems Questions and Answers
Fundamentals of Database Systems Questions and Answers
 
Database Q&A
Database  Q&ADatabase  Q&A
Database Q&A
 
Dbms Final Examination Answer Key
Dbms Final Examination Answer KeyDbms Final Examination Answer Key
Dbms Final Examination Answer Key
 
Previous question papers of Database Management System (DBMS) By SHABEEB
Previous question papers of Database Management System (DBMS) By SHABEEBPrevious question papers of Database Management System (DBMS) By SHABEEB
Previous question papers of Database Management System (DBMS) By SHABEEB
 
Final paper FN511 Switching & Routing
Final paper FN511 Switching & RoutingFinal paper FN511 Switching & Routing
Final paper FN511 Switching & Routing
 
Chapter2
Chapter2Chapter2
Chapter2
 
Int306 04
Int306 04Int306 04
Int306 04
 
FP 301 OOP FINAL PAPER JUNE 2013
FP 301 OOP FINAL PAPER JUNE 2013FP 301 OOP FINAL PAPER JUNE 2013
FP 301 OOP FINAL PAPER JUNE 2013
 
DATABASE Fp304 chapter 1
DATABASE Fp304   chapter 1DATABASE Fp304   chapter 1
DATABASE Fp304 chapter 1
 
Tcc apresentacao redes wi-fi
Tcc apresentacao redes wi-fiTcc apresentacao redes wi-fi
Tcc apresentacao redes wi-fi
 
OBJECT ORIENTED ROGRAMMING With Question And Answer Full
OBJECT ORIENTED ROGRAMMING With Question And Answer  FullOBJECT ORIENTED ROGRAMMING With Question And Answer  Full
OBJECT ORIENTED ROGRAMMING With Question And Answer Full
 
Computer Based Math
Computer Based MathComputer Based Math
Computer Based Math
 
Computer Math Day 03 Addition
Computer Math Day 03 AdditionComputer Math Day 03 Addition
Computer Math Day 03 Addition
 
Computer math
Computer mathComputer math
Computer math
 
[SpLab3]Structures
[SpLab3]Structures[SpLab3]Structures
[SpLab3]Structures
 
C++ TUTORIAL 1
C++ TUTORIAL 1C++ TUTORIAL 1
C++ TUTORIAL 1
 
Fskik 1 nota
Fskik 1   notaFskik 1   nota
Fskik 1 nota
 
Ccna training report
Ccna training reportCcna training report
Ccna training report
 
Bcsl 031 solve assignment
Bcsl 031 solve assignmentBcsl 031 solve assignment
Bcsl 031 solve assignment
 
2009 Punjab Technical University B.C.A Database Management System Question paper
2009 Punjab Technical University B.C.A Database Management System Question paper2009 Punjab Technical University B.C.A Database Management System Question paper
2009 Punjab Technical University B.C.A Database Management System Question paper
 

Ähnlich wie FINAL PAPER FP304 DATABASE SYSTEM

this is about databases questions , maybe i miss copy some option D,.docx
this is about databases questions , maybe i miss copy some option D,.docxthis is about databases questions , maybe i miss copy some option D,.docx
this is about databases questions , maybe i miss copy some option D,.docx
EvonCanales257
 
Suppose that a PRODUCT table contains two attributes, PROD_CODE an.docx
Suppose that a PRODUCT table contains two attributes, PROD_CODE an.docxSuppose that a PRODUCT table contains two attributes, PROD_CODE an.docx
Suppose that a PRODUCT table contains two attributes, PROD_CODE an.docx
picklesvalery
 
C programming session 02
C programming session 02C programming session 02
C programming session 02
Vivek Singh
 
Exploring Microsoft Office 2010 Volume 1 Excel Chapter 2Testbank.docx
Exploring Microsoft Office 2010 Volume 1 Excel Chapter 2Testbank.docxExploring Microsoft Office 2010 Volume 1 Excel Chapter 2Testbank.docx
Exploring Microsoft Office 2010 Volume 1 Excel Chapter 2Testbank.docx
POLY33
 
QUESTION 1What type of items are valid for use in the value list o.docx
QUESTION 1What type of items are valid for use in the value list o.docxQUESTION 1What type of items are valid for use in the value list o.docx
QUESTION 1What type of items are valid for use in the value list o.docx
teofilapeerless
 

Ähnlich wie FINAL PAPER FP304 DATABASE SYSTEM (20)

SQL MCQ
SQL MCQSQL MCQ
SQL MCQ
 
this is about databases questions , maybe i miss copy some option D,.docx
this is about databases questions , maybe i miss copy some option D,.docxthis is about databases questions , maybe i miss copy some option D,.docx
this is about databases questions , maybe i miss copy some option D,.docx
 
284566820 1 z0-061(1)
284566820 1 z0-061(1)284566820 1 z0-061(1)
284566820 1 z0-061(1)
 
Suppose that a PRODUCT table contains two attributes, PROD_CODE an.docx
Suppose that a PRODUCT table contains two attributes, PROD_CODE an.docxSuppose that a PRODUCT table contains two attributes, PROD_CODE an.docx
Suppose that a PRODUCT table contains two attributes, PROD_CODE an.docx
 
1Z0-061 Oracle Database 12c: SQL Fundamentals
1Z0-061 Oracle Database 12c: SQL Fundamentals1Z0-061 Oracle Database 12c: SQL Fundamentals
1Z0-061 Oracle Database 12c: SQL Fundamentals
 
Oracle OCP 1Z0-007题库
Oracle OCP 1Z0-007题库Oracle OCP 1Z0-007题库
Oracle OCP 1Z0-007题库
 
Johor trial-09-c
Johor trial-09-cJohor trial-09-c
Johor trial-09-c
 
Dump Answers
Dump AnswersDump Answers
Dump Answers
 
Dbms lab questions
Dbms lab questionsDbms lab questions
Dbms lab questions
 
Chapter 3 ( PART 2 ).pptx
Chapter 3 ( PART 2 ).pptxChapter 3 ( PART 2 ).pptx
Chapter 3 ( PART 2 ).pptx
 
C programming session 02
C programming session 02C programming session 02
C programming session 02
 
Exploring Microsoft Office 2010 Volume 1 Excel Chapter 2Testbank.docx
Exploring Microsoft Office 2010 Volume 1 Excel Chapter 2Testbank.docxExploring Microsoft Office 2010 Volume 1 Excel Chapter 2Testbank.docx
Exploring Microsoft Office 2010 Volume 1 Excel Chapter 2Testbank.docx
 
T6
T6T6
T6
 
QUESTION 1What type of items are valid for use in the value list o.docx
QUESTION 1What type of items are valid for use in the value list o.docxQUESTION 1What type of items are valid for use in the value list o.docx
QUESTION 1What type of items are valid for use in the value list o.docx
 
Dbms final quiz1
Dbms final quiz1Dbms final quiz1
Dbms final quiz1
 
BISH CS Modle Exit Exam.doc
BISH CS Modle Exit Exam.docBISH CS Modle Exit Exam.doc
BISH CS Modle Exit Exam.doc
 
Plsql pdf
Plsql pdfPlsql pdf
Plsql pdf
 
Computer paper 3 may june 2004 9691 cambridge General Certificate of educatio...
Computer paper 3 may june 2004 9691 cambridge General Certificate of educatio...Computer paper 3 may june 2004 9691 cambridge General Certificate of educatio...
Computer paper 3 may june 2004 9691 cambridge General Certificate of educatio...
 
Oracle 12C SQL 3rd Edition Casteel Test Bank
Oracle 12C SQL 3rd Edition Casteel Test BankOracle 12C SQL 3rd Edition Casteel Test Bank
Oracle 12C SQL 3rd Edition Casteel Test Bank
 
S3 Data Processing Pre-Waec Examination (First Half)
S3 Data Processing Pre-Waec Examination (First Half)S3 Data Processing Pre-Waec Examination (First Half)
S3 Data Processing Pre-Waec Examination (First Half)
 

Kürzlich hochgeladen

1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
QucHHunhnh
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
SoniaTolstoy
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
QucHHunhnh
 
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
kauryashika82
 

Kürzlich hochgeladen (20)

Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajan
 
General AI for Medical Educators April 2024
General AI for Medical Educators April 2024General AI for Medical Educators April 2024
General AI for Medical Educators April 2024
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
 
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
 
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
 
Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdf
 
fourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writingfourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writing
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..
 
Disha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfDisha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdf
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
 

FINAL PAPER FP304 DATABASE SYSTEM

  • 1. CONFIDENTIAL FP304 DATABASE SYSTEM Page 2 of 20 SECTION A OBJECTIVE QUESTIONS (50 marks) INSTRUCTION: This section consists of FORTY (40) objective questions. Answer ALL questions in the answer booklet. 1. “A software system that enable user to define, create and maintain the database”. This statement describes [CLO 1] A. Oracle 10g B. Microsoft Office Access 2007 C. Database Management System D. Data warehouse 2. The function of a database is to ____________. [CLO 1] A. collect and organize input data B. check all input data C. check all spelling D. output data 3. Choose the software that is commonly used in database. [CLO 1] A. Oracle B. SQL Access C. SQL desktop D. Linux 4. Internal Schema is one of the three-schema architecture. Which one is true about Internal Schema? [CLO 1] A. It hides the details of physical storage structures and concentrates on describing entities, data types, relationships, user operations, and constraints. B. Uses a physical data model and describes the complete details of data storage and access paths for the database.
  • 2. CONFIDENTIAL FP304 DATABASE SYSTEM Page 3 of 20 C. Implementation of data model D. The part of the database that a particular user is interested in and hides the rest of the database from user 5. A _____________ is the set of allowable values for one or more attributes. [CLO 1] A.Cardinality B.Tuple C.Degree D.Domain 6. Within a table, the primary key must be unique so that it will identify each row. When this is the case, the table is said to exhibit ________ integrity. [CLO 1] A. Referential B. Entity C. Enforced D. Key 7. The data type of values that appear in each column is represented by _________________ of possible values. [CLO 1] A. Range B. Product C. Domain D. Function
  • 3. CONFIDENTIAL FP304 DATABASE SYSTEM Page 4 of 20 8. Based on Figure 1, identify which one is the Candidate Key? Figure 1 [CLO 1] A. W B. X C. Y D. Z 9. All companies operate four departments in their organization. This relationship represents a _______________. [CLO 1] A. one-to-one relationship. B. one-to-many relationship. C. many-to-one relationship. D. many-to-many relationship. 10. __________________works on a single relation R and defines a relation that constrains only those tuples (rows) of R that satisfy the specified condition (predicate). [CLO 1] A. Cartesian product B. Difference C. Selection D. Intersection
  • 4. CONFIDENTIAL FP304 DATABASE SYSTEM Page 5 of 20 11. _________________ works on a single relation R and defines a relation that contains a vertical subset of R, extracting the values of specified attributes and eliminating duplicates. [CLO 1] A. Projection B. Cartesian Product C. Difference D. Intersection 12. The ______________set operator combines all tuples from two relations excluding duplicates. [CLO 1] A. Union B. Intersect C. Difference D. Divide 13. The ___________ operator returns all tuples in one relation that are not found in other relation. [CLO 1] A. Intersect B. Product C. Select D. Difference 14. What is meant by the term union compatibility? [CLO 1] A. When two or more tables share the same number of columns B. When two or more tables have the same degree C. When two or more tables share the same domains D. When two or more tables share the same number of columns and when they share the same domain
  • 5. CONFIDENTIAL FP304 DATABASE SYSTEM Page 6 of 20 15. What is meant by the following relational algebra statement? STUDENT x COURSE [CLO 1] A. Compute the natural join between the STUDENT and COURSE relations. B. Compute the left outer join between the STUDENT and COURSE relations. C. Compute the Cross Product between the STUDENT and COURSE relations. D. Compute the outer join between the STUDENT and COURSE relations. Question 16,17 and 18 are based on Figure 2 : Figure 2 16. A relational algebra operator applied to tables of EMPLOYEES and DEPARTMENT produces the following result as in Table 1 Table 1 The operator is: [CLO 3] A. An outer join operator B. The project operator C. The cross product operator D. The natural join operator
  • 6. CONFIDENTIAL FP304 DATABASE SYSTEM Page 7 of 20 17. A relational algebra operator applied to tables of EMPLOYEES and DEPARTMENT produces the following result as in Table 2 Table 2 The operator is: [CLO 3] A. An outer join operator B. The project operator C. The cross product operator D. The natural join operator 18. A relational algebra operator applied to tables of EMPLOYEES and DEPARTMENT produces the following result as in Table 3 Table 3 The operator is: [CLO 3] A. An outer join operator B. The project operator C. The cross product operator D. The natural join operator 19. Which clause would you use in a SELECT statement to limit the display to those employees whose salary is greater than 5000? [CLO 3] A. WHERE SALARY > 5000 B. HAVING SALARY > 5000
  • 7. CONFIDENTIAL FP304 DATABASE SYSTEM Page 8 of 20 C. ORDER BY SALARY > 5000 D. GROUP BY SALARY > 5000 20. You use this SQL statement to retrieve data from a table for ______________. [CLO 1] A. Viewing B. Deleting C. Inserting D. Updating 21. Which are Data Manipulation Language (DML) statements? i. SELECT ii. ALTER iii. DROP iv. DELETE [CLO 1] A. i, iv B. ii, iii C. i, ii, iii D. ii, iii, iv 22. What happens if the WHERE clause is omitted from a DELETE statement? [CLO 1] A. All records from the table are deleted B. No record from the table will be deleted C. First record of the table will be deleted D. The statement will not be executed and will give a syntax error SELECT * FROM orders;
  • 8. CONFIDENTIAL FP304 DATABASE SYSTEM Page 9 of 20 23. You need to produce a report for mailing labels for all customers. The mailing label must have only the customer name and address. The CUSTOMERS table has these columns: CUST_ID NUMBER(4) NOT NULL CUST_NAME VARCHAR2(100) NOT NULL CUST_ADDRESS VARCHAR2(150) CUST_PHONE VARCHAR2(20) Which SELECT statement accomplishes this task? [CLO3] A. SELECT *FROM CUSTOMERS; B. SELECT CUST_NAME, CUST_ADDRESS, CUST_PHONE FROM CUSTOMERS; C. SELECT CUST_ID,CUST_NAME,CUST_ADDRESS, CUST_PHONE FROM CUSTOMERS; D. SELECT CUST_NAME, CUST_ADDRESS FROM CUSTOMERS; 24. Which INSERT statement is correct to insert a new row into table of employees? A. INSERT INTO employees (employee_id) VALUES (1000); B. INSERT INTO employees VALUES (NULL, ‘John’, ‘Smith’); C. INSERT INTO employees (first_name, last_name) VALUES (‘John’, ‘Smith’); D. INSERT INTO employees (first_name, last_name, employee_id) VALUES (100, ‘John’, ‘Smith’);
  • 9. CONFIDENTIAL FP304 DATABASE SYSTEM Page 10 of 20 25. How to select all the records from a table named ‘Persons’ where the value of the column “FirstName” starts with an “a” using SQL statement? [CLO 3] A. SELECT * FROM Persons WHERE FirstName LIKE ‘%a’; B. SELECT * FROM Persons WHERE FirstName= ‘a’; C. SELECT * FROM Persons WHERE FirstName LIKE ‘a%’; D. SELECT * FROM Persons WHERE FirstName LIKE ‘%a%’; 26. In UPDATE statement, choose the correct answer to update firstname = Mary to firstname = Marry from a table named "staff". [CLO 3] A. UPDATE RECORD staff SET FName = 'Marry' WHERE LName = 'Mary'; B. UPDATE staff SET FName = 'Marry' WHERE LName = 'Mary'; C. UPDATE staff SET INTO FName = 'Marry' WHERE LName = 'Mary'; D. UPDATE RECORD staff SET INTO FName = 'Marry' WHERE LName = 'Mary'; 27. A goal of normalization is to minimize _____________. [CLO 1] A. the number of relationships B. the number of entities C. the number of tables D. data redundancy 28. A table that satisfies 2NF ___________________. [CLO 1] A. always satisfies 1NF B. may violate 1NF C. always satisfies 3NF D. always satisfies BCNF 29. On an entity-relationship diagram, a diamond represents a ___________.
  • 10. CONFIDENTIAL FP304 DATABASE SYSTEM Page 11 of 20 [CLO 1] A. multivalued attribute B. data flow C. entity D. relationship 30. A person, place, object, event, or concept in the user environment about which the organization wishes to maintain data refers to a(n): ___________________ . [CLO 1] A. Cardinality B. Attribute C. Relationship D. Entity 31. When applying the optional 1-M relationship rule for converting an ERD into a relational table design, which of the following statements is true? [CLO1] A. Each 1-M relationship with 0 for the minimum cardinality on the parent side becomes a new table. B. The primary key of the new table is the primary key of the entity type on the child (many) side of the relationship. C. The new table contains foreign keys for the primary keys of both entity types participating in the relationship. D. Both foreign keys in the new table do not permit null values. 32. What type of relationship is expressed with the phrase "Student takes Class"? [CLO 1] A. 1 : M B. M : 1 C. 1 : 1 D.M : N 33. When applying the M-N relationship rule for converting an ERD into a relational table design, which of the following statements is true?
  • 11. CONFIDENTIAL FP304 DATABASE SYSTEM Page 12 of 20 i. Each M-N relationship becomes a separate table ii. The foreign keys must not allow null values. iii. The primary key of the table is a combined key consisting of the primary keys of the entity types participating in the M-N relationship. iv. The primary key of the table is the primary key of the entity type participating in the M-N relationship which has the most attributes. [CLO 1] A. i,ii B. i,iii C. i,ii,iii D. ii,iii,iv 34. Based on Figure 3 the BOOKS and MEMBER entities are related to each other. The relationship on the MEMBER side indicates that: Figure 3 [CLO 1] A. A BOOKS may be borrowed by one or more MEMBER. B. A MEMBER may borrow one BOOKS. C. A BOOKS may be borrowed by zero or one MEMBER only. D. A MEMBER may borrow zero or more BOOKS.
  • 12. CONFIDENTIAL FP304 DATABASE SYSTEM Page 13 of 20 35. Choose the correct Entity Relationship Model diagram based on the situation given. “Each INSTRUCTOR may teach one or more CLASS” “Each CLASS is taught by one INSTRUCTOR” [CLO 1] A. B. C. . D. 36. ______________ refers to the requirement that other operations cannot access data that has been modified during a transaction that has not yet been completed. [CLO 2] A. Consistent B. Isolated C. Durable D. Atomic C INSTRUCTOR CLASS teach 1 1 ((0, N) (1,1) C INSTRUCTOR CLASS teach (1,N) (1,1) 1 M C INSTRUCTOR CLASS teach (0,1) (1,1) 1 1 C INSTRUCTOR CLASS teach (0,N) (1,1) 1 M
  • 13. CONFIDENTIAL FP304 DATABASE SYSTEM Page 14 of 20 37. _____________is the ability of the DBMS to recover the committed transaction updates against any kind of system failure. [CLO 2] A. Consistent B. Isolated C. Durable D. Atomic 38. Deadlocks are possible only when one of the transactions wants to obtain a (n) _________________ lock on a data item. [CLO 2] A. Binary B. Exclusive C. Shared D. Complete 39. Which of the following term below refers to the statement stated below? [CLO 2] A. Consistent B. Durable C. Atomic D. Isolated  All of the tasks of a database transaction must be completed  If incomplete due to any possible reasons, the database transaction must be aborted.
  • 14. CONFIDENTIAL FP304 DATABASE SYSTEM Page 15 of 20 40. If locking is not available and several users access a database concurrently, problems may occur if their transactions use the same data at the same time. Concurrency problems include i. Lost or buried updates. ii. Uncommitted dependency iii. Inconsistent analysis iv. Transaction Log [CLO 2] A. i B. ii,iii C. i,ii,iii D. i,iii,iv
  • 15. CONFIDENTIAL FP304 DATABASE SYSTEM Page 16 of 20 SECTION B STRUCTURED QUESTIONS (50 marks) INSTRUCTION: This section consists of TWO (2) structured questions. Answer ALL questions. QUESTION 1 a) ANSI-SPARC Architecture, is an abstract design standard for a Database Management System (DBMS), first proposed in 1975. Given ANSI- SPARC architecture in Figure 1.1, explain each level. Figure 1.1 [CLO 1] (3 marks) b) Database is a collection of persistent data that can be shared and interrelated. i. Explain TWO (2) properties of database. ii. Explain TWO (2) features of Database Management System. [CLO 1] (4 marks) [CLO 1] (2 marks) c) Illustrate THREE (3) most common relationships in E-R models. [CLO 1] (3 marks)
  • 16. CONFIDENTIAL FP304 DATABASE SYSTEM Page 17 of 20 STUDENT STU_NUM STU_LNAME 321452 Bowser 324257 Smithson ENROLL CLASS_CODE STU_NUM ENROLL_GRADE 10014 321452 C 10014 324257 B 10018 321452 A 10018 324257 B 10021 321452 C 10021 324257 C CLASS CLASS_CODE CRS_CODE CLASS_SECTION CLASS_TIME CLASS_ROOM PROF_NUM 10014 ACCT-211 3 THUR, 2:30- 3.45PM BUS252 342 10018 CIT-220 2 MON, 9:00- 9:50PM KLR211 114 10021 QM-261 1 WED, 8:00- 8:50AM KLR200 114 d) Study the tables STUDENT, ENROLL and CLASS in Figure 1.2: Figure 1.2 i. Determine primary key for each table ii. Determine foreign keys for these tables iii. Write suitable command to create a new table consisting of class code, student number, class room and class time [CLO 3] (2 marks) [CLO 3] (2 marks) [CLO3] (4 marks)
  • 17. CONFIDENTIAL FP304 DATABASE SYSTEM Page 18 of 20 e) Draw the ER Diagram for relational schemes in Figure 1.3: PRODUCT ( product_code, product_name, price, brand) BUYS ( recipt_no, product_code, quantity, discount, sub_total) RECIPT ( receipt_no, date, customer_no) CUSTOMER ( customer_no, name, address, phone_no) Figure 1.3 [CLO 3] (5 marks) QUESTION 2 a) i) Explain TWO (2) properties of database transaction. ii) Explain TWO (2) types of recovery tools. [CLO 1] (4 marks) [CLO 2] (2 marks) b) Identify THREE (3) DDL statements in SQL and the function of each statement. [CLO 1] (3 marks) c) Describe the terms below: i. Normalization ii. Second Normal Form (2NF) iii. Third Normal Form (3NF) [CLO 1] (3 marks)
  • 18. CONFIDENTIAL FP304 DATABASE SYSTEM Page 19 of 20 d) Generate the output for the following SQL statements based on Table 2.1. Table 2.1 i. SELECT vehicleID, platNo, yearProduce, model FROM vehicle WHERE yearProduce >= 2000 ORDER BY yearProduce asc ii. SELECT vehicleID, platNo, model FROM vehicle WHERE model LIKE “Perodua%” iii. SELECT vehicleID, platNo, yearProduce FROM vehicle WHERE price < 20000 iv. SELECT SUM(price) FROM vehicle [CLO 3] (2 marks) (2 marks) (2 marks) (2 marks)
  • 19. CONFIDENTIAL FP304 DATABASE SYSTEM Page 20 of 20 e) Table 2.2 shows a list of patient appointments with the doctor. Each patient is given the time and date of appointment with doctors in a particular room. Show the steps on how you make the process of normalization stage 1NF, 2NF and 3NF. Appointment [CLO 3] (5 marks) Table 2.2 NoBilik Tarikh Masa AT020123 Kamal 1/12/2002 10.00 S15 AT00111 Jamaliah 1/12/2002 12.00 S15 CT00456 Sudin 1/12/2002 10.00 S10 CT00456 Sudin 14/1/2002 14.00 S10 AT00111 Jamaliah 14/1/2002 16.30 S15 AT00103 Abu 15/1/2002 18.00 S13 NamaPesakit Temujanji 8765 Shamsul 8602 Maizul 8111 Aziz Staff# Nama_Doktor Pesakit#