A Java Swing-based ATM/Bank Management desktop application backed by a MySQL (DBMS) database.
- Project Overview
- Features
- Tech Stack
- Database Schema
- Project Structure
- Screenshots / Module Descriptions
- Setup & Installation
- How to Run
- Known Issues & Improvements
- Author
Bank Management System is a desktop application that simulates an ATM/Bank interface. It allows users to sign up for a bank account, log in with their card number and PIN, and perform banking transactions such as deposits, withdrawals, PIN changes, balance enquiry, and viewing mini statements.
All data is stored and managed using a MySQL relational database, making it a complete DBMS-based project.
| Feature | Description |
|---|---|
| π User Sign Up | 3-page registration form collecting personal, additional, and account details |
| π Login | Secure login using Card Number + PIN |
| π° Deposit | Deposit any amount into the account |
| πΈ Withdrawal | Withdraw up to Rs. 10,000 per transaction |
| β‘ Fast Cash | Quick withdrawal with preset amounts (Rs. 100, 500, 1000, 2000, 5000, 10000) |
| π Mini Statement | View last 10 transactions with date, type, and amount |
| π³ Balance Enquiry | View current account balance |
| π PIN Change | Change the 4-digit ATM PIN securely |
| πͺ Exit | Safely exit the application |
- Language: Java (JDK 8+)
- UI Framework: Java Swing (AWT)
- Database: MySQL 8.x
- JDBC Driver: MySQL Connector/J
- Additional Library: JDateChooser (
com.toedter.calendar) β for date picker in signup - IDE: IntelliJ IDEA / Eclipse / NetBeans
Database Name: banksystem
| Column | Type | Description |
|---|---|---|
form_number |
VARCHAR | Form/Application number |
card_number |
VARCHAR | 16-digit card number |
pin_number |
VARCHAR | 4-digit PIN |
| Column | Type | Description |
|---|---|---|
form_number |
VARCHAR | Unique application form number |
name |
VARCHAR | Full name |
father_name |
VARCHAR | Father's name |
dob |
VARCHAR | Date of birth |
gender |
VARCHAR | Gender |
email |
VARCHAR | Email address |
marital_status |
VARCHAR | Married / Unmarried / Other |
address |
VARCHAR | Residential address |
city |
VARCHAR | City |
pincode |
VARCHAR | Postal PIN code |
state |
VARCHAR | State |
| Column | Type | Description |
|---|---|---|
form_number |
VARCHAR | Foreign key β signup |
religion |
VARCHAR | Religion |
category |
VARCHAR | General / OBC / SC / ST / Other |
income |
VARCHAR | Annual income range |
education |
VARCHAR | Educational qualification |
occupation |
VARCHAR | Occupation type |
pan_number |
VARCHAR | PAN card number |
aadhar_number |
VARCHAR | Aadhar card number |
senior_citizen |
VARCHAR | Yes / No |
existing_account |
VARCHAR | Yes / No |
| Column | Type | Description |
|---|---|---|
form_number |
VARCHAR | Foreign key β signup |
account_type |
VARCHAR | Saving / Fixed Deposit / Current / Recurring |
card_number |
VARCHAR | Auto-generated 16-digit card number |
pin_number |
VARCHAR | Auto-generated 4-digit PIN |
facilities |
VARCHAR | Selected services (ATM, Internet Banking, etc.) |
| Column | Type | Description |
|---|---|---|
pin_number |
VARCHAR | Foreign key β login |
date |
VARCHAR | Transaction date & time |
type |
VARCHAR | Deposit or Withdrawl |
amount |
VARCHAR | Transaction amount |
CREATE DATABASE banksystem;
USE banksystem;
CREATE TABLE login (
form_number VARCHAR(20),
card_number VARCHAR(20),
pin_number VARCHAR(10)
);
CREATE TABLE signup (
form_number VARCHAR(20),
name VARCHAR(100),
father_name VARCHAR(100),
dob VARCHAR(20),
gender VARCHAR(10),
email VARCHAR(100),
marital_status VARCHAR(20),
address VARCHAR(200),
city VARCHAR(50),
pincode VARCHAR(10),
state VARCHAR(50)
);
CREATE TABLE signuptwo (
form_number VARCHAR(20),
religion VARCHAR(20),
category VARCHAR(20),
income VARCHAR(30),
education VARCHAR(30),
occupation VARCHAR(30),
pan_number VARCHAR(20),
aadhar_number VARCHAR(20),
senior_citizen VARCHAR(5),
existing_account VARCHAR(5)
);
CREATE TABLE signupthree (
form_number VARCHAR(20),
account_type VARCHAR(40),
card_number VARCHAR(20),
pin_number VARCHAR(10),
facilities VARCHAR(200)
);
CREATE TABLE bank (
pin_number VARCHAR(10),
date VARCHAR(50),
type VARCHAR(20),
amount VARCHAR(20)
);bank.management.system/
β
βββ Login.java β Login screen (Card Number + PIN)
βββ Signup.java β Registration Page 1 (Personal Details)
βββ Signup2.java β Registration Page 2 (Additional Details)
βββ Signup3.java β Registration Page 3 (Account & Card Setup)
βββ main_Class.java β Main ATM Menu (Transaction Selection)
βββ Deposit.java β Deposit money
βββ Withdrawl.java β Custom amount withdrawal
βββ FastCash.java β Quick preset-amount withdrawal
βββ BalanceEnquriy.java β Check account balance
βββ mini.java β Mini statement (last 10 transactions)
βββ Pin.java β Change PIN
βββ Connn.java β Database connection utility (MySQL via JDBC)
icon/
βββ bank.png β Bank logo icon
βββ atm2.png β ATM background image
βββ backbg.png β Login page background
The entry screen of the application. Users log in with their Card Number and PIN. On successful authentication, they are directed to the main ATM menu. New users can navigate to the Sign Up flow.
A 3-page account registration flow:
- Page 1: Personal details (name, DOB, gender, email, address)
- Page 2: Additional info (religion, income, PAN, Aadhar)
- Page 3: Account type selection and auto-generation of Card Number & PIN
The central ATM dashboard with buttons for all 7 operations. Buttons include a hover effect for better UX.
Allows the user to deposit any custom amount. Validates that the field is not empty before inserting the transaction record.
Custom amount withdrawal with a maximum limit of Rs. 10,000 per transaction. Validates sufficient balance before processing.
Provides 6 quick-select withdrawal amounts: Rs. 100, 500, 1000, 2000, 5000, 10000. Checks balance before debiting.
Calculates the running balance by summing all Deposits and subtracting all Withdrawals for the logged-in PIN.
Displays the last 10 transactions in a scrollable panel. Deposits are shown in green and withdrawals in red. Also shows the masked card number and current total balance.
Allows the user to change their 4-digit PIN. Updates across all three relevant tables (bank, login, signupthree).
Database utility class that establishes a JDBC connection to the banksystem MySQL database.
- Java JDK 8 or higher
- MySQL Server 8.x
- MySQL Connector/J JAR (add to project classpath)
- JCalendar library (
jcalendar-1.4.jaror newer β for date picker)
git clone https://github.com/yourusername/bank-management-system.git
cd bank-management-system- Open MySQL Workbench or the MySQL CLI.
- Run the SQL script from the Database Schema section above.
- Verify the database
banksystemand all 5 tables are created.
Open Connn.java and update the credentials to match your MySQL setup:
connection = DriverManager.getConnection(
"jdbc:mysql://localhost:3306/banksystem",
"root", // β your MySQL username
"yourpassword" // β your MySQL password
);Add the following JARs to your project's build path:
mysql-connector-java-x.x.x.jarjcalendar-1.4.jar
- Open the project in your IDE (IntelliJ / Eclipse / NetBeans).
- Ensure all JAR dependencies are added to the classpath.
- Run
Login.javaas the main entry point. - To create a new account, click SIGN UP and complete the 3-page form.
- After sign-up, you will receive your auto-generated Card Number and PIN β note them down.
- Log in using those credentials to access the ATM menu.
| Issue | Suggestion |
|---|---|
| SQL Injection vulnerability in most queries | Use PreparedStatement throughout (currently only mini.java uses it) |
Amount stored as VARCHAR in bank table |
Change to INT or DECIMAL for proper numeric operations |
| PIN stored in plain text | Hash PINs using BCrypt before storing |
| No session timeout | Add inactivity timer to auto-logout |
| PIN change uses wrong column name | Queries reference pin instead of pin_number β fix for correct update |
Signup2.java has a bug |
Both scitizen and eAccount read from the same radio button group (r1/r2) β should use separate groups |
| No input validation on amounts | Add numeric checks and prevent negative values |
| Hard-coded window sizes | Make UI responsive or use layout managers |
PVS Bank Management System Built as a DBMS mini/major project using Java Swing and MySQL.
This project is intended for educational purposes only. Feel free to fork and improve it.