Professional Documents
Culture Documents
Result Management SysteM
Result Management SysteM
College Logo
Report Title
Submitted Date
Report Title
Submitted by
Submitted to
Date
Acknowledgment
Table of Contents
1. Introduction .................................................................................................................. 1
1.1 Background ................................................................................................................ 1
1.2 Objectives .............................................................................................................. 1
2. Database Design and Development .............................................................................. 1
2.1 Database Design ......................................................................................................... 1
2.1.1 ER Diagram of Student Result Management System .............................................. 2
2.1.1.1 Cardinality Mapping ........................................................................................ 3
2.1.1.2 Individual Entity Relationship ......................................................................... 4
2.1.2 Schema Design ............................................................................................... 5
2.2 Database Development .......................................................................................... 6
2.2.1 Entity and Attribute Creation (DDL) .................................................................. 6
2.2.2 Anomalies and Normalization ........................................................................... 11
2.2.3 Integrity Constraint Management ...................................................................... 11
3. Data Testing ............................................................................................................... 12
3.1 Entry record in each table......................................................................................... 12
3.2 Updating, Deletion and Selection ........................................................................ 16
3.2.1 Updating Query ............................................................................................ 16
3.2.2 Deletion ........................................................................................................ 17
4. SQL ............................................................................................................................ 19
4.1 Simple Queries ......................................................................................................... 19
4.2 Subqueries ........................................................................................................... 20
4.3 Join ...................................................................................................................... 21
5. Conclusion and Knowledge Gained ........................................................................... 22
1. Introduction
1.1 Background
In our education system, the success rate of teaching and learning phenomenon is based on
the progress report of the student. The educational institution should keep the record of its
student. For preparing the progress report of students and to keep their records, large
amount of data is required. These data should be stored in effective way so that they are
easily accessible and easy to manipulate. Therefore, student result management system has
been introduced to manage the information about the student, subjects offered by
educational institution in every level, marks obtained by student in every subject, records
of the exams and finally prepare the progress report of the student. Student result
management system is an effective way to automate the manual result system.
1.2 Objectives
o To manage the details of student, course, exam, progress and result.
o To reduce the manual work of managing the result information.
o To provide the information searching facilities based on various factors.
o Like: result, progress, exam, etc.
o To improve editing, adding and updating of records with proper
management of data.
o To integrate the record of all exam.
1 of 22
2.1.1 ER Diagram of Student Result Management System
dept_id
dept_member Department
dept_name
offers
conduct
enrolls
c_code
c_name
course exam_id
reg_no credits
name
Assign has
ed to
semester
GPA result
sem_num
grade
year
sub_id
sem_name
c_code
marks std_id
2 of 22
2.1.1.1 Cardinality Mapping
a) One-to-One
An entity in A is associated with at most one entity in B and vice-versa. This is
called one to one relationship. In our ER diagram, we have following one to one
relationship:
• One student is assigned to one semester.
• One course is divided into one semester.
b) One-to-many
An entity in A is associated with any number of B and an entity in B is associated
with at most one entity from set A. This is one-to-many relationship. In our ER
diagram we have following one-to-many relationships.
• One department enrolls many students.
• One department offers many course.
• One department conduct many exams.
• One exam have many results.
3 of 22
2.1.1.2 Individual Entity Relationship
enrolls
Department student
course Divided_
semester
into
4 of 22
2.1.2 Schema Design
student exam
semester
result
5 of 22
sub_id
c_code
year
std_id
2.2 Database Development
We have design our system by using ER diagram. Now the development of the student
result management system is done by using SQL.
--Department
create table Department
(
dept_id integer,
dept_name varchar(30),
dept_member integer,
constraint PK_Department primary key(dept_id)
);
--student
create table student
(
reg_no integer,
std_id integer,
name varchar(30),
DOB date,
Gender char(6),
contact bigint,
add_code int,
constraint student_fk foreign key (add_code) references address(add_code),
constraint PK_student primary key(std_id)
);
6 of 22
--address
create table address(
add_code int,
zone varchar(10),
district varchar(10),
city varchar(10),
street_name varchar(10),
ward int,
constraint address_pk primary key (add_code)
);
--course
create table course
(
c_code integer,
c_name varchar(20),
credits integer,
constraint PK_course primary key(c_code)
);
--exam
create table exam
(
exam_id integer,
exam_name varchar(30),
constraint PK_exam primary key(exam_id)
);
7 of 22
--semester
create table semester
(
c_code int,
sem_number integer,
cyear bigint,
sem_name varchar(30),
constraint PK_semester primary key(sem_number),
constraint semester_FK foreign key(c_code) references course (c_code)
);
--result
create table result
(
std_id int,
c_code int,
GPA numeric,
Letter_grade char(2),
marks integer,
constraint PK_result primary key(std_id),
constraint result_FK foreign key(std_id) references student(std_id),
);
alter table result add foreign key(c_code) references course(c_code) on delete cascade;
--Relation table
--offer
create table offer
(
c_code int,
dept_id int,
constraint offer_FK foreign key(c_code) references course(c_code)
);
alter table offer add foreign key(dept_id) references Department(dept_id)
on delete cascade;
8 of 22
--Relation table
--enrolls
create table enrolls
(
dept_id int,
std_id int,
constraint enrolls_FK foreign key(dept_id) references department(dept_id),
);
alter table enrolls add foreign key(std_id) references student(std_id)
on delete cascade;
--Relation table
--assign_to
create table assign_to
(
std_id int,
sem_number int,
constraint assign_to_FK foreign key(std_id) references student(std_id)
);
alter table assign_to add foreign key(sem_number) references semester(sem_number)
on delete cascade;
--Relation table
--conducts
create table conducts
(
dept_id int,
exam_id int,
constraint conducts_FK foreign key(dept_id) references department(dept_id),
);
alter table conducts add foreign key(exam_id) references exam(exam_id)
on delete cascade;
9 of 22
--Relation table
--held_in
create table held_in
(
sub_id int,
c_code int,
constraint held_in_FK foreign key(sub_id) references course(c_code),
);
alter table held_in add foreign key(c_code) references course(c_code)
on delete cascade;
--Relation table
--has
create table has
(
exam_id int,
std_id int,
constraint has_FK foreign key(exam_id) references exam(exam_id)
);
alter table has add foreign key(std_id) references student(std_id)
on delete cascade;
--Relation table
--divided_into
create table divided_into
(
c_code int,
sem_number int,
constraint divided_into_FK foreign key(c_code) references course(C_code)
);
alter table divided_into add foreign key(sem_number) references semester(sem_number)
on delete cascade;
10 of 22
2.2.2 Anomalies and Normalization
Anomalies are problems that can occurred in poorly planned, un-normalized database
where all the data stored in one table. There are especially three types of anomaly.
--semester
create table semester
(
c_code int,
sem_number integer,
cyear bigint,
sem_name varchar(30),
constraint PK_semester primary key(sem_number),
constraint semester_FK foreign key(c_code) references course (c_code)
);
11 of 22
3. Data Testing
Data testing is necessary step in database system development. Here the ACID property
validation, data mapping and data integrity are tested. But first we insert the data in every
tables in database system using insert command which is DML statement. After that we
use update, delete and select command in those data and analyze the result or the output.
12 of 22
--inserting values into course table
insert into course values(301,'dbms',48);
insert into course values(201,'microeconomics',48);
insert into course values(218,'dsa',48);
insert into course values(219,'web-ii',48);
insert into course values(202,'cost accounting',48);
insert into course values(101,'dLd',48);
insert into course values(102,'cis',48);
insert into course values(103,'co',48);
insert into course values(104,'dccn',48);
13 of 22
--inserting values into enrolls table
insert into enrolls values(1,100);
insert into enrolls values(1,101);
insert into enrolls values(1,102);
insert into enrolls values(2,103);
insert into enrolls values(2,104);
14 of 22
--inserting values into has table
insert into has values(1000,100);
insert into has values(1001,101);
insert into has values(1002,102);
insert into has values(1003,103);
insert into has values(1004,104);
15 of 22
3.2 Updating, Deletion and Selection
3.2.1 Updating Query
Before Updating
After Updating
16 of 22
3.2.2 Deletion
Before Deletion
After Deletion
17 of 22
3.2.3 Selection Table
Selecting all the records from the tables of our database system.
a) Select * from department
18 of 22
4. SQL
19 of 22
4.2 Subqueries
a) Display the detail of course where the student has secured highest marks in
their exam.
Ans: select course.* from course, result where course.c_code=result.c_code and
marks=(select max(marks) from result);
Output:
Output:
Output:
20 of 22
4.3 Join
a) Inner Join
Ans: select name, zone from student inner join address on
student.add_code=address.add_code;
Output:
b) Left Join
Ans: select name, district from student left join address on
student.add_code=address.add_code;
Output:
c) Right Join
Ans: select name, city from student left join address on
student.add_code=address.add_code;
Output:
21 of 22
5. Conclusion and Knowledge Gained
We have learned that student result management system is the effective automation of
manual result publication system. It provides easy interface to record the details of student,
courses, marks, exam and the progress report. Result of all the internal exams are
integrated. For generating final reports of a student large amount of data is required. They
should be stored in such a way that they are easily accessible and easy to manipulate the
data. And this system facilitate convenient storing and defining the information and also
maintain the security of the data.
With the help of student result management system, the publication of result, comparing
the efficiency of student, rewarding the deserving student, measure to increase the
efficiency of other students and other developmental decisions can be easily made. This
application will greatly simplify and speed up the result preparation and management
process.
22 of 22