0% found this document useful (0 votes)
2 views5 pages

Practical SQL Task- School Management System 2

The document outlines the design and implementation of a School Management System (SMS) using MySQL for a secondary school. It includes tasks such as creating a database, designing tables for students, teachers, courses, enrollment, exam results, and fees, as well as inserting data and querying the database for various reports. Additionally, it specifies basic, advanced, and modification queries to manage and analyze student and teacher information effectively.

Uploaded by

Ciara
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views5 pages

Practical SQL Task- School Management System 2

The document outlines the design and implementation of a School Management System (SMS) using MySQL for a secondary school. It includes tasks such as creating a database, designing tables for students, teachers, courses, enrollment, exam results, and fees, as well as inserting data and querying the database for various reports. Additionally, it specifies basic, advanced, and modification queries to manage and analyze student and teacher information effectively.

Uploaded by

Ciara
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 5

Practical SQL Task: School Management System

Scenario:

You have been hired as a database administrator for a secondary school. Your task is to design
and implement a School Management System (SMS) using MySQL. The system should
efficiently manage student records, teacher assignments, course enrollment, exam results, and
fees.

---

Task Breakdown:

1. Database Creation and Table Design

Create a database named SchoolDB.

Design and create tables for managing school operations with the following structure:

Tables:

1. Students

StudentID (Primary Key)

FirstName

LastName

DateOfBirth

Gender

Class

ParentContact

Address

2. Teachers
TeacherID (Primary Key)

FirstName

LastName

SubjectTaught

PhoneNumber

Email

Department

3. Courses

CourseID (Primary Key)

CourseName

TeacherID (Foreign Key references Teachers.TeacherID)

CreditHours

4. Enrollment

EnrollmentID (Primary Key)

StudentID (Foreign Key references Students.StudentID)

CourseID (Foreign Key references Courses.CourseID)

EnrollmentDate

5. ExamResults

ResultID (Primary Key)


StudentID (Foreign Key references Students.StudentID)

CourseID (Foreign Key references Courses.CourseID)

ExamDate

Score

Grade

6. Fees

FeeID (Primary Key)

StudentID (Foreign Key references Students.StudentID)

AmountDue

AmountPaid

PaymentStatus (Paid, Unpaid, Pending)

PaymentDate

PaymentMethod

---

2. Data Insertion

Insert at least 15 students, 5 teachers, and 10 courses.

Enroll students in courses.

Record exam results for students.

Generate fees records for at least 10 students.


---

3. Querying the Database

Basic Queries:

1. Retrieve all students enrolled in a specific course.

2. Find all courses taught by a specific teacher.

3. Get a list of students who have not paid their fees.

4. Retrieve exam results for a particular student.

Advanced Queries:

5. Find the total amount of fees paid by all students.

6. Retrieve students who scored below 50 in Mathematics.

7. Get a list of teachers who have the most students enrolled in their courses.

8. Identify students who have failed more than two courses.

Modification Queries:

9. Update the grade of a student who was given extra marks for an error in marking.

10. Delete records of students who have graduated and no longer attend the school.

You might also like