0% found this document useful (0 votes)
14 views22 pages

Suryansh and Vivek Comp

The document is a project report on a Flight Management System submitted by Suryansh Tiwari for the AISSCE exam. It outlines the project's purpose, which includes booking, canceling, and updating flight tickets, along with the coding details and database structure used in the project. The report also includes acknowledgments, hardware and software requirements, and a bibliography.

Uploaded by

klr044821
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
14 views22 pages

Suryansh and Vivek Comp

The document is a project report on a Flight Management System submitted by Suryansh Tiwari for the AISSCE exam. It outlines the project's purpose, which includes booking, canceling, and updating flight tickets, along with the coding details and database structure used in the project. The report also includes acknowledgments, hardware and software requirements, and a bibliography.

Uploaded by

klr044821
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 22

Central Board of Secondary Education

For AISSCE EXAM


Session – 2024-25
A PROJECT REPORT ON

FLIGHT MANAGEMENT SYSTEM

Submitted To Submitted By
Mr. Ankit Saxena SURYANSH TIWARI
Class : XII
CERTIFICATE

Certified that the work contained in the project titled


“FLIGHT MANAGEMENT SYSTEM”, by SURY ANSH
TIWARI
of class XII, has been carried out under my supervision and
that this work has not been submitted elsewhere for a
AISSCE certificate.

Teacher Name PRINCIPAL NAME STUDENT NAME


Mr. Ankit Saxena Mr. Hariom Singh SURY ANSH TIWARI
PGT-CS CLASS : XII
We declare that the work presented in this project titled
“FLIGHT MANAGEMENT SYSTEM”, submitted to
Mr. Ankit Saxena PGT Computer Science J.K.E.T.
CONVENT SCHOOL for the award of the CBSE -
AISSCE class XII certificate. We have not plagiarized or
submitted the same work for the award of any other
examination. In case this undertaking is found incorrect,
we accept that our Certificates may be unconditionally
withdrawn.

NAME OF THE STUDENT


SURY ANSH TIWARI

CLASS: XII
I would like to convey by heartfelt thanks to Mr. Ankit
Saxena my computer teacher who always gave valuable
suggestion and guidance for completion of my project.
He helped me to understand important details of the
project that I would have otherwise loss.
My project has only been success because of his
guidance. I am also very thankful to our honourable
principal Mr. Hariom Singh for the encouragement and
support he imparted to me in setting the forth project.

Student Name :
SURY ANSH TIWARI
Class:XII
1- Project Introduction
2- Imported Files & Used Functions in Python
3- Introduction about database & Tables
4- Coding of the Project
5- Output
6- Requirement of hardware and Software
7- Limitations
8- Bibliography
FLIGHT
MANAGEMENT
SYSTEM
Project Introduction

This is a program on the topic “FLIGHT


MANAGEMENT SYSTEM……..”.This
project helps the user to book flight tickets
according to their need. Passenger can
register their data.
Passenger can cancel their ticket without
any extra charges and can update their
journey date.

Imported Files & Used Functions


Modules: -

1- Import MySql for DataBase Connectivity

Functions:-

Pre-Defined Functions :

1- Connect() – For database and table connection.

2- Cursor() – For row by row processing of record in the


result set.

3- Execute()- For Execute an SQL statement.

4- Commit()- For change/update the database.

5-Fetchall()- For fetch all rows.


User-Defined Functions :

1-registerpass()-For adding passenger details like


name ,address, etc.

2-dispall()-For displaying all the passenger’s


details.

3-search()-For displaying particular data of a


passenger with the help of their unique passenger
no.

4-ticketprice()-For booking tickets in different


classes.

5-cancel()-for cancellation of tickets.

6-update()- for updating date of journey.


Database and Tables
Database :-

Name of the Database : FLIGHT


Total Number of tables : 2
Name of the Tables : 1- passdata 2- tkt

Tables:-

1-PASSDATA

2-TKT

Project Code
def registerpass():

passno=int(input("Enter passenger no = "))

name=input("Enter passenger name = ")

addr=input("Enter address = ")

jrdate=input("Enter date of journey =")

source=input("Enter source =")

dest=input("Enter destination =")

cur.execute("insert into
passdata(passno,name,addr,jrdate,source,dest)values('%d','%s','%s','%s',
'%s','%s')"%(passno,name,addr,jrdate,source,dest))

ob.commit()

def search():

cno=int(input("Enter the passenger name whose data to be viewed : "))

cur.execute("select * from passdata where passno="+str(cno))

fa=cur.fetchall()

for row in fa:

print(row)

'''for a in cur:

print(passno,"\t",name,"\t",addr,"\t",jrdate,"\t",source,"\t",dest)'''

ob.commit()
def dispall():

print("The customer details are as follows : ")

cur.execute("select * from passdata")

fa=cur.fetchall()

ob.commit()

k=(['passno','name','addr','jrdate','source','dest'])

for passno,name,addr,jrdate,source,dest in fa:

print(passno,"\t",name,"\t",addr,"\t",jrdate,"\t",source,"\t",dest)

ob.commit()

def ticketprice():

cno=int(input("Enter passenger no:"))

print("WE HAVE THE FOLLOWING CLASS FOR YOU : ")

print("ENTER 1 FOR BUSINESS CLASS :: RS 4000")

print("ENTER 2 FOR ECONOMY CLASS :: RS 3000")

print("ENTER 3 FOR LUXURY CLASS :: RS 5000")

x=int(input("Enter your choice ::"))

n=int(input("Enter number of passengers ::"))

if x==1:

print("YOU HAVE OPTED FOR BUSINESS CLASS")


s=4000*n

elif x==2:

print("YOU HAVE OPTED FOR ECONOMY CLASS")

s=3000*n

elif x==3:

print("YOU HAVE OPTED FOR LUXURY CLASS")

s=5000*n

else:

print("PLEASE SELECT APPROPRIATE OPTION")

print("YOUR TICKET CHARGE IS = ",s)

print("IF YOU WANT TO CARRY EXTRA LUGGAGE THERE IS


EXTRA OF 100 RS PER KG")

y=int(input("ENTER THE WEIGHT OF EXTRA LUGGAGE ="))

z=y*100

print("YOUR TOTAL BILL IS = ",s+z)

g_tot=s+z

cur.execute("insert into
tkt(passno,Ticket_fare,Luggage_fare,Total_fare)values('%d','%d','%d','
%d')"%(cno,s,z,g_tot))

ob.commit()

def cancel():

cno=int(input("Enter the passenger no of which the ticket is to be


cancelled= "))
cur.execute("delete from tkt where passno={}". format(cno))

print("TICKET CANCELLED SUCCESSFULLY")

def update():

cno=int(input("Enter passenger no "))

new_jr=input("enter new journey date =")

cur.execute("update passdata set jrdate='%s' where


passno='%d'"%(new_jr,cno))

ob.commit()

print("Updated Details Successfully")

print(" ೋღ ✿ ღೋ ೋღ ✿ ღೋ ೋღ ✿ ღೋೋღ ✿ ღೋ ೋღ ✿ ღೋ ೋღ ✿ ღೋ ")

print("🎀________________________________HI______________________
___________________🎀")

print("------------------------- WELCOME -------------------------")

print("******************** THIS IS THE PROJECT OF VIVEK


DIKSHIT & SURYANSH **********************")

print("############# TOPIC : FLIGHT MANAGEMENT SYSTEM


################# ")

print("❁•❁•❁•❁•❁•❁•❁❁•❁•❁•❁•❁•❁•❁❁•❁•❁•❁•❁•❁•❁•❁•❁•❁•❁❁•❁•❁•❁•

❁•❁")

print("⋆。‧˚ʚ♡ɞ˚‧。⋆⋆。‧˚ʚ♡ɞ˚‧。⋆⋆。‧˚ʚ♡ɞ˚‧。⋆⋆。‧˚ʚ♡ɞ˚‧。⋆⋆。‧˚ʚ♡ɞ˚‧。⋆⋆。‧˚ʚ♡ɞ˚‧。⋆⋆

。‧˚ʚ♡ɞ˚‧。⋆⋆。‧˚ʚ♡ɞ˚‧")
import mysql.connector as co

ob=co.connect(host="localhost",user="root",password="1234")

cur=ob.cursor()

cur.execute("create database if not exists Roadways")

cur.execute("use Roadways")

cur.execute("create table if not exists passdata(passno int not null primary


key,name varchar(30),addr varchar(30),jrdate date,source
varchar(30),dest varchar(30))")

cur.execute("create table if not exists tkt(passno int primary


key,Ticket_fare int,Luggage_fare int,Total_fare int)")

ob.commit()

while True:

print("Enter 1 :- TO ENTER PASSENGER DETAILS")

print("Enter 2 :- FOR TICKETBOOKING")

print("Enter 3 :- SHOW PASSENGERWISE DETAILS")

print("Enter 4 :- DISPLAY ALL DEATILS")

print("Enter 5 :- CANCEL TICKET")

print("Enter 6 :- TO UPDATE JOURNEY DATE")

print("Enter 7 :- EXIT")

ch=int(input("Enter your choice:-"))

if ch==1:

registerpass()
elif ch==2:

ticketprice()

elif ch==3:

search()

elif ch==4:

dispall()

elif ch==5:

cancel()

elif ch==6:

update()

elif ch==7:

break;

else:

print("!!!!PLEASE ENTER CORRECT CHOICE!!!!")

Output
Requirement of hardware and Software
Hardware :
1- Processor : Pentium ® G2030@ 3.70 GHz
2- RAM : 4 GB
3- System Architecture : 64 bits Operating System
4- HDD – 500 GB
Software :
1- Operating System : Window 8.1
2- IDE: IDLE Python
3- MySql
1- Printing Facility is not available.
1. python.org
2. Code Academy
3.tutorialsPoint.com
4. PythonChallenge.com
5. Google’s Python Class
6. LearnPython.org

You might also like