The Bus Reservation System is a Java-based application for booking bus tickets. It allows passengers to book seats on available buses and manages the booking details. This project is implemented using Java and MySQL for database management.
- Display a list of available buses.
- Allow passengers to book seats on a bus.
- Check seat availability for a particular bus on a given date.
- Store booking information in a MySQL database.
- Provide a user-friendly command-line interface.
Before running this project, make sure you have the following prerequisites installed:
-
Clone this repository to your local machine:
git clone https://github.com/Suhaib-Aamer/Bus-ReservationSystem
-
Import the project into your favorite Java IDE.
-
Configure your MySQL database connection by editing the DBConnection class with your database URL, username, and password.
-
Create a MySQL database named BusReservation.
-
Create the necessary tables in the database using the provided SQL schema.
-
Build and run the BusAdmin class to start the application.
-
Run the application by executing the BusAdmin class.
-
Follow the on-screen instructions to book bus tickets.
-
You can view available buses and their details.
-
Book seats on a bus by providing passenger information and selecting the desired date.
The project uses a MySQL database with the following schema:
- bus table: Stores information about buses, including bus number, AC status, and capacity.
- booking table: Stores booking details, including passenger name, bus number, and travel date.
- Contributions to this project are welcome. Please feel free to open issues, submit pull requests, or suggest new features and improvements. Together, we can make this project even better!