Skip to content
 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Employee Database Management System

Portfolio Project - A Java-based console application for managing employee records with MySQL database integration. This project demonstrates full-stack development skills including backend architecture, database design, user authentication, and object-oriented programming principles.

Key Features

  • Secure Authentication System: Implement credential verification and password hashing
  • Employee Data Management: CRUD operations for employee records
  • Role-Based Access Control: Different permission levels for admin and employee users
  • Admin Dashboard: Feature-rich interface with search, filtering, and bulk operations
  • Database Integration: MySQL backend with efficient data persistence
  • Password Security: Encrypted password storage using industry-standard hashing
  • MVC Architecture: Clean separation of concerns with Model, View, and Controller layers

Project Structure

├── bin/                      # Compiled class files
├── lib/                      # External libraries
├── src/                      # Source code
│   ├── Main.java            # Application entry point
│   ├── ConsoleLogin.java    # User login interface
│   ├── AdminConsole.java    # Admin management console
│   ├── EmployeeConsole.java # Employee interface
│   ├── Employee.java        # Employee data model
│   ├── User.java            # User data model
│   ├── DBConnector.java     # Database connection manager
│   ├── UserDAO.java         # User data access object
│   ├── UserInspector.java   # User inspection utilities
│   ├── CheckCredentials.java # Authentication logic
│   ├── HashPasswords.java   # Password hashing utility
│   ├── PasswordUtil.java    # Password utility functions
│   ├── ReportService.java   # Report generation service
│   ├── ReportController.java # Report control logic
│   ├── ReportRepository.java # Report data access
│   └── TestDB.java          # Database testing utilities

Getting Started

Prerequisites

  • Java Development Kit (JDK) 8 or higher
  • MySQL Server 5.7 or higher
  • MySQL JDBC Driver

Installation

  1. Clone or download the project
  2. Set up the MySQL database with required tables for users and employees
  3. Configure database connection settings in DBConnector.java
  4. Compile the Java source files:
    javac -d bin src/*.java
  5. Run the application:
    java -cp bin:lib/* Main

Usage

Logging In

The application starts with a login prompt. Enter your credentials to access the system based on your user role.

Admin Console

Once logged in as an admin, access features from the menu:

  • Search for employees
  • View recently hired employees
  • Edit employee information
  • Update salaries in bulk
  • Generate various reports

Employee Console

Employee users can view their own information and access limited features.

Architecture & Design Patterns

  • Model Layer: Employee.java, User.java - Data models with encapsulation
  • Data Access Layer: UserDAO.java, ReportRepository.java - DAO pattern for database operations
  • Service Layer: ReportService.java - Business logic separation
  • Presentation Layer: AdminConsole.java, EmployeeConsole.java, ConsoleLogin.java - Console UI interfaces
  • Utility Layer: Reusable components for password hashing, database connections, and authentication

Database

The system uses MySQL for data persistence. Key tables include:

  • users - User accounts with encrypted passwords
  • employees - Employee records with personal and employment information

Security Features

  • Password hashing for secure credential storage
  • User authentication with role-based access control
  • SQL prepared statements to prevent injection attacks

Skills Demonstrated

  • Java Programming: Core language features, OOP principles, exception handling
  • Database Design: MySQL schema design, normalization, relationships
  • JDBC: Database connectivity and SQL query execution
  • Authentication & Security: Password hashing, credential validation, role-based access
  • Design Patterns: DAO, MVC, Service Layer patterns
  • Software Architecture: Clean code, separation of concerns, modularity
  • Console Application Development: User interface design for CLI applications

Technologies Used

  • Language: Java 8+
  • Database: MySQL 5.7+
  • JDBC: Java Database Connectivity API
  • Build: Java Compiler (javac)
  • Architecture: MVC (Model-View-Controller) pattern

Contributing

To contribute improvements to this project:

  1. Create a feature branch
  2. Make your changes
  3. Test thoroughly
  4. Submit a pull request

Code Quality

This project emphasizes:

  • Clean, readable code with meaningful variable names
  • Proper exception handling and error management
  • Object-oriented design principles
  • Reusable, modular components
  • Security best practices

About

Employee management database system

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages