Airlines Database

Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 11

Design Problem II

Software
Engineering
Airlines Reservation System

Submitted To
Mr. Sartaj Singh
Lect. In Software Engg.
Submitted By
Rahul Soni
A3803B38
MCA Hons.

April
27,2009
Airlines Database
Flight Details.

tblFLIGHT

Flight NO VARCHAR2(10) PRIMARY KEY


Flight Name VARCHAR2(25) NOT NULL
Airline Number NUMBER(4) NOT NULL
Origin Code NUMBER(4) NOT NULL (REFERENCES
tblTERMINAL.Terminal
Code)
Destination Code NUMBER(4) NOT NULL (REFERENCES
tblTERMINAL.Terminal
Code)
Capacity NUMBER(3) NOT NULL

tblFLIGHT DETAILS

Flight NO VARCHAR2(10) Primary Key (REFERENCE


tblFLIGHT.Flight NO)
Terminal Code NUMBER(4) Primary Key (REFERENCES
tblTERMINAL.Terminal Code)
Price NUMBER NOT NULL
Booked NUMBER(3) NOT NULL
Date DATE PRIMARY KEY

tblTERMINAL

Terminal Code NUMBER(4) Primary Key


Terminal Name VARCHAR2(30) Not Null

CUSTOMER DETAILS
tblPASSENGER

User Id VARCHAR2(3) Foreign Key


REFERENCES
tblUser.User Id
Customer Id VARCHAR2(6) Primary Key
Customer Name VARCHAR2(25) -
Address VARCHAR2(50) -
Email VARCHAR2(25) -
Pin Code VARCHAR2(6) -
Phone No VARCHAR2(15) -
Total Miles NUMBER(4) -
Payment Type VARCHAR2(10) NOT NULL
Credit Card No VARCHAR2(20) -

tblUser

User Id VARCHAR2(3) Primary Key


User Name VARCHAR2(25) Not Null
Address VARCHAR2(50) Not Null
Email VARCHAR2(25) Not Null
Phone No VARCHAR2(15) Not Null

tblCustomerFeedback

User Id Varchar2(3) Primary Key


References
tblUser.User Id
User Name Varchar2(25) Not Null
Feedback Score Number(2) Not Null
Comment Varchar2(50)
RESERVATION DETAILS

tblReservationDetails

Customer Id Varchar2(6) Primary Key


References
tblPassenger.Cust
omer Id
Flight No Varhcar2(10) Foreign Key
References
tblFlight.FlightDet
ail
Booking Date DATE Primary Key
TakeOff Date DATE NOT NULL
Status Number(1) Foreign Key
References
tblStatus.StatusId

tblStatus

StatusId Number(1) Primary Key


Status Varchar2(10) NOT NULL

tblStatus table will store the different status against a


particular StatusId . For ex. 0 for On Time, 1 for delayed
flight, 2 for cancelled flight, 3 for waiting state etc.
Facilities available in the system

To find the best airlines on the basis of maximum


bookings.
 Using tblFlightDetails

Select the maximum value of “Booked” column from


tblFlight.

“Select * from tblFlightDetails order by booking”

Cancellation Facility
 Using a cascade delete operation on multiple tables

 The “Booked” column in tblFlights decremented by 1 for


each cancellation.

 All the details corresponding to that particular


“Customer Id” is deleted from the “tblPassenger” table
from database.

 All the reservation details are deleted from the table


“tblReservationDetails” according to that very
“CustomerId”.
Customer Feedback
 Customer inputs its feedback in form of Feedback score,
which can range from 0 to 10. Another option is “comment”
which is optional.

User can comment upon the services of the company.

Data Flow Diagrams.


Level 0 DFD
A level 0 Data flow Diagram showing the most abstract view of the
system. The User is authenticated through entering the username and
password. The details are matched with the entries in the database
and a correct match is allowed to access the database.
The level 1 DFD shown above depicts how the
user accesses the airlines and the database of
the system.
A level II DFD showing the
details of customer
information and flight
information and the possible
operations that can be applied
on them. Level 2 DFD
Level 3 DFD showing the updation of the
table as user write into the
tblReservationDetail table of the database
while booking a seat and delete entry from
the table while cancelling a booking.

You might also like