Professional Documents
Culture Documents
UNIVERSITY
Faculty of Computer Science and Engineering
Assignment 02
Submitted to
Dr. Md. Samsuzzaman
Professor
Department of Computer and Communication
Engineering
Faculty of Computer Science and Engineering
Patuakhali Science and Technology University, Dumki,
Patuakhali, Bangladesh
Submitted by:
MD. TASNIF RAHMAN
ID No : 1802014
Reg No : 08424
Review Questions and Answers:
Data : Data is any sort of information which is stored in computer memory.
This information can later be used for a website, an application or any other
client to store for future purpose.
Src:[https://www.google.com/search?
q=A+Database+is+a+collection+of+related+data+with+an+implicit+meaning.&oq=A+Database+is+a+collection+of+related+
data+with+an+implicit+meaning.&aqs=chrome..69i57.2472j0j4&sourceid=chrome&ie=UTF-8]
If queries (screens and reports) are not running fast enough, the
designers.developers need to check for bottlenecks in their code,
and the DBA’s need to check for bottlenecks in memory, I/O, or
the network. The designers may need to create new indexes, or
add statistics to the database so that queries execute faster - these
objects will need space from the DBA’s, and maybe changes to
table definitions to create/update statistics.
Src:[ https://www.coursehero.com/file/p3jv6smv/14-What-are-the-responsibilities-of-the-DBA-and-the-
database-designers-The-DBA/#:~:text=The%20DBA%20are%20responsible%20to,structures%20to
%20store%20this%20data.]
Casual End Users
Naive or parametric end users
Sophisticated end users
Standalone users
*Naive end users need to learn very little about the facilities provided by
the DBMS
*Casual users learn only a few facilities that they may use repeatedly
Exercise:
Identify some informal queries and update operations that you
would expect to apply to the database shown in Figure 1.2.
Ans:
(a) (Query) List the names of all students majoring in Computer
Science.
(b) (Query) What are the prerequisites of the Database
course?
(c) (Query) Retrieve the transcript of Smith. This is a list of Course
Name,
Section_identifier, Semester, Year, Grade> for each course section that
Smith has
completed.
(d) (Update) Insert a new student in the database whose Name=Jackson,
Student_number=23, Class=1 (freshman), and Major=MATH.
(e) (Update) Change the grade that Smith received in Intro to Computer
Science section
119 to B.
Fig:1.2
Specify all the relationships among the records of the database shown
in Figure 1.2.
Ans:
Fig:1.2
In the section 1.2 example, we have auniversity database for maintaining
information concerning students, courses, and grades in a university
environment. The database here is organized as five files, each of which
stores data records of the same type.
COURSE: The COURSE file stores data on each course. It includes the
data to represent theCourse_name, Course_number, Credit_hours, and
Department.
Ans:
A view that groups all the students who took each section and gives each
student's grade. This may be useful for printing the grade report for each
section for the university administration's use.
(b) A view that gives the number of courses taken and the GPA
(grade point average) for each student. This may be used to determine
honors students.
1.12. Cite some examples of integrity constraints that you think can
apply to the database shown in Figure 1.2.
Ans: Examples:
(a) The Student_number should be unique for each STUDENT record
(key constraint).
(b) The Course_number should be
unique for each COURSE record (key constraint).
(c) A value of Course_number in a SECTION record must also exist in
some COURSE
record (referential integrity constraint).
(d) A value of Student_number in a GRADE_REPORT record must also
exist in some
STUDENT
record (referential integrity constraint).
(e) The value of Grade in a GRADE_REPORT record must be one of
the values in the set
{A, B, C, D, F, I, U, S} (domain constraint).
(f) Every record in COURSE must have a value for Course_number
(entity integrity constraint).
(g) A STUDENT record cannot have a value of Class=2 (sophomore)
unless the student
has completed a number of sections whose total course Credit_hours is
greater th at 24 credits (general semantic integrity constraint)