A web-based university examination management system built with Node.js, Express, and MySQL. Developed as a project for an RDBMS class.
This system supports three user roles: admin, faculty, and student each with their own dashboard and set of features. Admins manage users and subjects, faculty create exams and enter marks, and students view their enrolled subjects, upcoming exams, and results.
Admin
- Dashboard with counts of students, faculty, subjects, exams, and results
- Create, edit, and delete student accounts with automatic subject registration
- Create, edit, and delete faculty accounts with subject assignment
- Manage subjects (add, edit, delete)
- Assign or remove faculty from subjects
- View an overview of all exams and results across the system
Faculty
- Dashboard showing assigned subjects and upcoming exams
- View students enrolled in each subject
- Create exams (Midterm, Endterm, Practical) for one or more subjects
- Enter and save student marks
Student
- Dashboard showing enrolled subjects, upcoming exams, and recent results
- View subject details including assigned faculty
- View upcoming exam schedule
- View full results with marks and grades
- Runtime: Node.js
- Framework: Express 5
- Database: MySQL
- Templating: EJS
- Styling: Vanilla CSS
university-exam-system/
db.js # MySQL connection pool
server.js # App entry point
routes/
auth.js # Login / logout
admin.js # Admin routes
faculty.js # Faculty routes
student.js # Student routes
views/
login.ejs
admin/ # Admin page templates
faculty/ # Faculty page templates
student/ # Student page templates
partials/ # Shared sidebar components
public/
style.css
script.js
users— id, name, email, password, registration_no, role (admin / faculty / student)subjects— id, name, code, department, semester, credits, faculty_idregistrations— student_id, subject_idexams— id, subject_id, exam_date, exam_typeresults— id, exam_id, student_id, marks, grade
-
admin: admin@university.ac.in
-
student: priya.patel@student.ac.in
-
faculty: vikram.nair@university.ac.in
-
password for all: 1234
- Node.js >= 18
- MySQL server running locally
-
Clone the repository:
git clone https://github.com/slyeet03/university-exam-system.git cd university-exam-system -
Install dependencies:
npm install
-
Create a
.envfile in the root directory:DB_HOST=localhost DB_USER=your_mysql_user DB_PASS=your_mysql_password DB_NAME=your_database_name DB_PORT=3306 SESSION_SECRET=your_secret_key PORT=3000 -
Set up your MySQL database and run the necessary table creation scripts (not included — create tables matching the schema above).
-
Start the development server:
npm run dev
Or for production:
npm start
-
Open your browser and go to
http://localhost:3000.
MIT


