Class12 CS Project Hospital Management System Bhavan New (1) Button
Class12 CS Project Hospital Management System Bhavan New (1) Button
SURAPET
COMPUTER SCIENCE
NAME:RAGURAM S
CLASS: 12 A2
ROLL NUMBER:
Surapet, for the partial fulfilment of Computer science Practical examination conducted
by Senior School Certificate Examination-CBSE, New Delhi for the academic Year
2024- 2025.
Date: ……………………..
Apart from the efforts taken by me, the success of the project depends largely on the
encouragement and guidelines of many others. I take this opportunity to express my
gratitude to the people who have been instrumental in the successful completion of this
project.
I express deep sense of gratitude to almighty God for giving me the strength to
complete the project successfully.
My sincere thanks to Ms. Sowmiya a guide, mentor, above all a friend, who
critically reviewed my project and guided me during the implementation of the project.
The guidance and support received from all the members who contributed, was vital
for the success of the project. I am grateful for their constant support and help.
1. ABSTRACT
2. SYSTEM CONFIGURATION
3. INTRODUCTION
4. OBJECTIVES OF THE PROJECT
5. PROPOSED SYSTEM
6. LIBRARIES AND FUNCTIONS USED
7. MYSQL QUERIES USED IN THIS PROJECT
8. SOURCE CODE
9. OUTPUT (SCREENSHOT)
10. CONCLUSION
11.BIBILOGRAPHY
ABSTRACT:
Hospital Management System project is developed using Python and MySQL Database.
This application provides an easy way to the admin in searching the details of the patients,
doctors, nurses and complete history of the patient. Hospital Management system project
in Python is a simple console application. In this project, users can perform typical report
card related functions like adding a new patient record and displaying and deleting it.
SYSTEM CONFIGURATION:
HARDWARE CONFIGURATION
Microsoft windows 7 professional/windows 8/windows 8.2:
Processor : Intel Core i3 or equivalent
Memory : 2 GB (32-bit), 4 GB (64-bit)
Disk space : 1.5 GB of free disk space
SOFTWARE REQUIREMENTS
1 GB RAM (2 GB+ recommended)
9-58 GB free hard disk space depending on edition and configuration, including
space required for temporary files
DVD-ROM drive (if installing from a Media Kit DVD)
Basic GPU – Any vendor DirectX 9.0 class or better (Pixel Shader Level 2)
Intel® Pentium® or compatible, 1.6 GHz minimum (2GHz+ recommended)
1024x768 or higher-resolution monitor
1. Manage Appointments
• Appointment widgets will be built into the sites of hospitals
Appointment widgets will be built into the sites of hospitals that have their own. When
people go to the hospital’s website, they can easily appointment Bookings online.
2. Manage Doctors
• In this feature manage all the information’s of the Doctors /
In this feature manage all the information’s of the Doctors/Nurses and each Doctor
Patients inside the hospital
3. Manage Patients
• HMS makes it possible to get all of a patient’s information
HMS makes it possible to get all of a patient’s information through a system with just
a few clicks.
• The user can see information like the patient’s medical history,
The user can see information like the patient’s medical history, current illness, doctors
involved, test results, billing information, and much more.
• These pieces of information will help put together what we
These pieces of information will help put together what we know about the patient,
such as their specific diagnosis, treatment, and medications.
PROPOSED SYSTEM
One cannot rely on flawed people in today’s fierce competition, where “to err is human” is
no longer true. Furthermore, it is no longer appropriate to excuse one’s mistakes. To keep up
with the times, achieve the best results without any issues, and increase productivity, the
endless heaps of flies have been replaced with a computer’s hard drive.
Use of the data management tool is required. More and more businesses have failed as a
result of software. With so many technological options available, businesses could operate
more quickly and effectively. Data administration used to require a lot of ledger upkeep and
paper work, but software technologies have made their work more productive and labour-
intensive. The only tool required to complete work on the computer at the moment is this
application.
This results in significant time and financial savings. All business-related information is
accessible by pressing a button, and the process is fully automated. Moreover, automating a
business improves its reputation because we live in a technological age.
About Hospital Management System Project Python
The Hospital Management System Project is a system project console-based system
which is easy to use. In This Article you will learn step-by-step process on how to create
a Hospital Management System Project.
A Project for Hospital Management System is a education purposes only.
Importance of Hospital Management System
Hospital management is important because it allows healthcare to run in a structured
way and makes it easier to offer many different services.
It lets large hospitals that offer a wide range of services keep better track of their finances
by better planning the flow of money, making better investments, and controlling costs.
LIBRARIES USED:
FUNCTIONS USED:
The following are custom functions used to manage various operations within the
system:
1. patient_detail():
o Purpose: Collects the data entered in the patient fields and inserts a new patient
record into the Patients table in the MySQL database and also view or modify
or delete the details of the patient.
2. doctor_details():
o Purpose: Collects the data entered in the doctor fields and inserts a new doctor
record into the Doctors table in the MySQL database and also view or modify
or delete the details of the doctor.
3. nurse_details():
o Purpose: Collects the data entered in the nurse fields and inserts a new nurse
record into the Nurses table in the MySQL database and also view or modify or
delete the details of the nurse.
4. other_workers_details():
o Purpose: Collects the data entered in the nurse fields and inserts a new worker
record into the Other Workers table in the MySQL database and also view or
modify or delete the details of the worker.
Purpose: Clears all input fields in the GUI to allow for new entries after an operation is
completed.
MYSQL QUERIES USED:
1. Creating Tables
3. Retrieving Data
Retrieving All Patients/Doctors/Nurses/Other workers:
select * from doctor_details;
select * from nurse_details;
select * from other_workers_details;
select * from patient_detail;
4. Deleting Data
Delete the Patient/Doctor/Nurse/Other worker:
delete from doctor_details where name='" + name + "';
delete from nurse_details where name='" + name + "';
delete from other_workers_details where name='" + name + "';
delete from patient_detail where name='" + name + "';
SOURCE CODE:
while (True):
print("""
================================
Welcome To CityHospital
================================
""")
# creating database connectivity
import mysql.connector
passwd = str(input("Enter the Password Please!!:"))
mysql = mysql.connector.connect(
host="localhost", user="root", passwd=passwd)
mycursor = mysql.cursor()
mycursor.execute("create database if not exists city_hospitals")
mycursor.execute("use city_hospitals")
# creating the tables we need
mycursor.execute(
"create table if not exists patient_detail(name varchar(30) primary key,sex
varchar(15),age int(3),address varchar(50),contact varchar(15))")
mycursor.execute("create table if not exists doctor_details(name varchar(30) primary
key,specialisation varchar(40),age int(2),address varchar(30),contact varchar(15),fees
int(10),monthly_salary int(10))")
mycursor.execute(
"create table if not exists nurse_details(name varchar(30) primary key,age int(2),address
varchar(30),contact varchar(15),monthly_salary int(10))")
mycursor.execute(
"create table if not exists other_workers_details(name varchar(30) primary key,age
int(2),address varchar(30),contact varchar(15),monthly_salary int(10))")
# creating table for storing the username and password of the user
mycursor.execute(
"create table if not exists user_data(username varchar(30) primary key,password
varchar(30) default'000')")
while (True):
print("""
1. Sign In
2. Registration
""")
=======================================
!!!!!!!!!!Register Yourself!!!!!!!!
=======================================
""")
u = input("Input your username!!:")
p = input("Input the password (Password must be strong!!!:")
mycursor.execute(
"insert into user_data values('" + u + "','" + p + "')")
mysql.commit()
print("""
============================================
!!Well Done!!Registration Done Successfully!!
============================================
""")
x = input("enter any key to continue:")
# IF USER WANTS TO LOGIN
elif r == 1:
print("""
==================================
!!!!!!!! {{Sign In}} !!!!!!!!!!
==================================
""")
un = input("Enter Username!!:")
ps = input("Enter Password!!:")
mycursor.execute(
"select password from user_data where username='" + un + "'")
row = mycursor.fetchall()
for i in row:
a = list(i)
if a[0] == str(ps):
while (True):
print("""
1.Administration
2.Patient(Details)
3.Sign Out
""")
4. Make an exit
""")
b = int(input("Enter your Choice:"))
# details
if b == 1:
print("""
1. Doctors Details
2. Nurse Details
3. Others
""")
1. Doctor Details
2. Nurse Details
3. Others
""")
c = int(input("ENTER YOUR CHOICE:"))
# enter doctor details
if c == 1:
# ASKING THE DETAILS
name = input("Enter the doctor's name")
spe = input("Enter the specilization:")
age = input("Enter the age:")
add = input("Enter the address:")
cont = input("Enter Contact Details:")
break
print("""
1. Show Patients Info
2. Add New Patient
3. Discharge Summary
4. Exit
""")
b = int(input("Enter your Choice:"))
# showing the existing details
# if user wants to see the details of PATIENT
if b == 1:
mycursor.execute(
"select * from patient_detail")
row = mycursor.fetchall()
for i in row:
b=0
v = list(i)
k = ["NAME", "SEX", "AGE",
"ADDRESS", "CONTACT"]
d = dict(zip(k, v))
print(d)
elif a == 3:
break
OUTPUT:
CONCLUSION:
This system saves the time of the administrator. It includes process like Patient/Doctor
addition, displaying, deleting.
This makes the system easy to handle and feasible for finding the omission with updating
at the same time.
If filed a query to search or update in a manual system, it will take a lot of time to process
the query and make a report which is a tedious job.
This computerized system store all the data in the database which makes it easy to fetch
and update whenever needed.
BIBILOGRAPHY:
HTTPS://WWW.W3SCHOOLS.COM/PYTHON/
PYTHON_MYSQL_GETSTARTED.ASP
HTTPS://WWW.TUTORIALSPOINT.COM/PYTHON/PYTHON_DATABASE
_ACCESS.HTM HTTPS://PYTHONSPOT.COM/MYSQL-WITH-PYTHON/