
















Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!

















A Project report Submitted In Partial Fulfillment of the Requirements In COMPUTER SCIENCE (083)
We declare that the work presented in this project titled "TRAIN MANAGEMENT SYSTEM", submitted to Mr. John Thomas TGT Computer Science ST. THOMAS PUBLIC SCHOOL, DIPKA for the award of the CBSE-AISSE 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. MARCH, 202 2 Place: ST. THOMAS PUBLIC SCHOOL, DIPKA
**1. Khushi Dewangan - XII A - ROLL NO:
I express my sincere gratitude to Rev. Siju Robert, Principal of St. Thomas Public School, Pragati Nagar, Dipka, Korba, Chhattisgarh. We are deeply indebted to our mentor Mr. John Thomas. We futher thank to all the staff members of St. Thomas Public School, Dipka. We owe our sincere gratitude towards St. Thomas Public School. Our heartfelt thanks to CBSE. We also express our deepest gratitude to our parents. Finally, we would like to wind up by paying our heartfelt thanks to all our near and dear ones.
**1. Khushi Dewangan - XII A - ROLL NO:
The following figure is a graphical representation of the various stages of a typical SDLC. A typical Software Development Life Cycle consists of the following stages – Stage 1: Planning and Requirement Analysis Requirement analysis is the most important and fundamental stage in SDLC. It is performed by the senior members of the team with inputs from the customer, the sales department, market surveys and domain experts in the industry. This information is then used to plan the basic project approach and to conduct product feasibility study in the economical, operational and technical areas. Planning for the quality assurance requirements and identification of the risks associated with the project is also done in the planning stage. The outcome of the technical feasibility study is to define the various technical approaches that can be followed to implement the project successfully with minimum risks.
Stage 2: Defining Requirements Once the requirement analysis is done the next step is to clearly define and document the product requirements and get them approved from the customer or the market analysts. This is done through an SRS (Software Requirement Specification) document which consists of all the product requirements to be designed and developed during the project life cycle. Stage 3: Designing the Product Architecture SRS is the reference for product architects to come out with the best architecture for the product to be developed. Based on the requirements specified in SRS, usually more than one design approach for the product architecture is proposed and documented in a DDS - Design Document Specification. This DDS is reviewed by all the important stakeholders and based on various parameters as risk assessment, product robustness, design modularity, budget and time constraints, the best design approach is selected for the product. A design approach clearly defines all the architectural modules of the product along with its communication and data flow representation with the external and third party modules (if any). The internal design of all the modules of the proposed architecture should be clearly defined with the minutest of the details in DDS. Stage 4: Building or Developing the Product In this stage of SDLC the actual development starts and the product is built. The programming code is generated as per DDS during this stage. If the design is performed in a detailed and
Database A database is a separate application that stores a collection of data. Each database has one or more distinct APIs for creating, accessing, managing, searching and replicating the data it holds. Other kinds of data stores can also be used, such as files on the file system or large hash tables in memory but data fetching and writing would not be so fast and easy with those type of systems. Nowadays, we use relational database management systems (RDBMS) to store and manage huge volume of data. This is called relational database because all the data is stored into different tables and relations are established using primary keys or other keys known as Foreign Keys. A Relational DataBase Management System (RDBMS) is a software that −
RDBMS Terminology Before we proceed to explain the MySQL database system, let us revise a few definitions related to the database.
What is Python? Python is a popular programming language. It was created by Guido van Rossum, and released in 1991. It is used for:
System Requirements of the Project Recommended System Requirements
Database
Source Code #Defining the Function for searching Trains def train_search(): print("(NOTE- While searching for trains, Please Start with Capital Letter.)") print("[--FOR EXAMPLE:- 'Your Origin: Bilaspur']") print() print() #Provide the origin station user_input=input("Your Origin: ") #Provide the destination station user_input1=input("Your Destination: ") #Query to fetch trains between origin and destination query1= "SELECT * FROM train_details WHERE origin='{}' AND destination='{}' ".format(user_input,user_input1) cur.execute(query1) records=cur.fetchall() if len(records)==0: print("-----Enter Valid - [Origin/Destination]-----") #Provide the Day of Travel else: user_input2=input("Day On Which You Wish to Travel: ")
for row in records: if user_input2==row[6] or user_input2==row[7] or user_input2==row[8] or user_input2==row[9] or user_input2==row[10] or user_input2==row[11] or user_input2==row[12]: print("Total Number of Trains Found: ",cur.rowcount ) print("Train Number: ",row[0]) print("Train Name: ",row[1]) print("Origin Station: ",row[2]) print("Destination Station: ",row[3]) print("Departure Time: ",row[4]) print("Destination Arrival Time: ",row[5] ) print("On-time Efficiency: ",row[13]) print("Meal on Board: ",row[22]) else: print("No Trains Available!!.. Try some Other Options [Origin/Destination/Day] ") break user_input3=input("In which Coach would you like to travell(Sleeper/3AC/2AC/1AC)? : ") if user_input3=='Sleeper': print("Available SL seats :",row[14]) print("Fare for SL seat :",row[18])