0% found this document useful (0 votes)
41 views28 pages

DBMS Project

Uploaded by

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

DBMS Project

Uploaded by

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

A

Project Report on

TAXIES DATABASE MANAGEMENT SYSTEM


Submitted for partial fulfilment of the requirements for the award of the degree
of

BACHELOR IN TECHNOLOGY IN
ARTIFICIAL INTELLIGENCE & DATA SCIENCE
By S.MD.ASHIK - 22K81A7251
Under the guidance of
Mr. S.ANTONY DHAS
Assistant professor

DEPARTMENT OF ARTIFICIAL INTELLIGENCE & DATA SCIENCE


St.MARTIN’S ENGINEERING COLLEGE
UGC Autonomous
Affliated to JNTUH,Approved by AICTE Accredited by NBA & NAAC
A+,ISO 9001-2008 Certified
Dhulapally,Secunderabad-500 100
St. MARTIN'S ENGINEERING COLLEGE
UGC Autonomous
NBA& NAAC A+
Accredited
Dhulapally, Secunderabad - 500 100
www.smec.ac.in

Certificate
This is to certify that the project entitled "Taxies DataBase Management System" is being
submitted by S.MD.ASHIK(22K81A7251) in fulfilment of the requirement for the award of
degree of BACHELOR OF TECHNOLOGY IN ARTIFICIAL INTELLIGENCE &
DATA
SCIENCE is recorded of bonafide work carried out by them. The result embodied in this report
have been verified and found satisfactory.

Project Internal Examiner Signature of HOD


Mr. S.ANTONY DHAS Dr B.RAJALINGAM
Assistant professor Associate Professor and Head of Department
Department of AI & DS Department of AI & DS
St. MARTIN'S ENGINEERING COLLEGE
UGC Autonomous
NBA& NAAC A+ Accredited
Dhulapally, Secunderabad - 500 100
www.smec.ac.in

DEPARTMENT OF ARTIFICIAL INTELLIGENCE & DATA SCIENCE

DECLARATION

We, the students of "Bachelor of Technology in Department of Artificial Intelligence & Data Science(AI&D
embodied in this project report has not been submitted in any university for award of any degree.

S.MD.ASHIK-22K81A7251
ACKNOWLEDGEMENT

The satisfaction and euphoria that accompanies the successful completion of any task would be
incomplete without the mention of the people who made it possible and whose encouragement and
guidance have crowded our efforts with success. First and foremost, we would like to express our
deep sense of gratitude and indebtedness to our College Management for their kind support and
permission to use the facilities available in the Institute.

We especially would like to express our deep sense of gratitude and indebtedness to
Dr. P. SANTOSH KUMAR PATRA, Group Director, St. Martin’s Engineering College
Dhulapally,for permitting us to undertake this project.

We wish to record our profound gratitude to Dr. M. SREENIVAS RAO, Principal, St. Martin’s
Engineering College, for his motivation and encouragement.

We are also thankful to Dr. B. RAJALINGAM, Head of the Department, Artificial Intelligence
and Data Science(AI&DS), St. Martin’s Engineering College, Dhulapally, Secunderabad, for his
support and guidance throughout our project.

We would like to express our sincere gratitude and indebtedness to our project supervisor
Mr.S.ANTONY DHAS Assistant Professor, Department of Artificial Intelligence & Data Science,
St. Martins Engineering College, Dhulapally, for his/her support and guidance throughout our
project.

Finally, we express thanks to all those who have helped us successfully completing this project.
Furthermore, we would like to thank our family and friends for their moral support and
encouragement. We express thanks to all those who have helped us in successfully completing the
project.

S.MD.ASHIK-22K81A7251
CONTENTS
ACKNOWLEDGEMENT i

CHAPTER 1-ABSTRACT 1

CHAPTER 2-INTRODUCTION 2

CHAPTER 3-LITERATURE SURVEY 3

CHAPTER 4- SYSTEM ANALYSIS 4

CHAPTER 5- SYSTEM REQUIREMENTS

5.1 HARDWARE REQUIREMENTS 5

5.2 SOFTWARE REQUIREMENTS 6

ALGORITHM 7 -8

CHAPTER 6- SYSTEM IMPLEMENTATION

SOURCE CODE 9 -17

CHAPTER 7- SYSTEM TESTING 18

CHAPTER 8-EXPERIMENTAL RESULTS 19

CHAPTER 9-CONCLUSION & FUTURE ENHANCEMENT 20

CHAPTER 10 – REFERENCES 21
CHAPTER 1

ABSTRACT

The Taxi Database Management System (TDMS) is a robust and comprehensive solution designed
to streamline and enhance the operations of taxi services. This project focuses on developing a
centralized database system that efficiently manages a wide range of taxi-related activities,
including driver information, vehicle details, trip records, customer information, and billing
processes. TDMS aims to provide a user-friendly interface for administrators, drivers, and
customers, ensuring seamless data entry, retrieval, and management.

Key features of TDMS include real-time tracking of taxis, automated scheduling and dispatching,
detailed reporting and analytics, and secure handling of sensitive information. The system
leverages advanced technologies such as GPS for location tracking, cloud computing for data
storage, and modern web frameworks for an intuitive user experience.

The development of TDMS involves thorough requirements analysis, database design,


implementation, testing, and deployment. The project addresses critical challenges such as data
redundancy, security, and scalability, ensuring the system can handle a growing number of users
and transactions. By providing an integrated platform for managing taxi services, TDMS aims to
improve operational efficiency, enhance customer satisfaction, and support the overall growth of
the taxi industry.

Overall, TDMS represents a significant advancement in the digital transformation of taxi services,
offering a scalable and secure solution that meets the dynamic needs of modern transportation
management.

1
CHAPTER 2

INTRODUCTION

The Taxi Database Management System (TDMS) is an innovative project designed to revolutionize
the management of taxi services through the implementation of a centralized, efficient, and user-
friendly database system. As the demand for taxi services continues to grow, the need for an
organized and reliable system to handle the various aspects of taxi operations becomes increasingly
critical. TDMS addresses this need by offering a comprehensive solution that integrates driver
management, vehicle maintenance, trip scheduling, customer interactions, and billing processes
into a single cohesive platform.

TDMS aims to simplify and optimize the operational workflow of taxi companies by providing a
centralized repository for all data related to their services. The system enables administrators to
manage driver profiles, track vehicle status, monitor trips in real-time, and generate detailed
reports. It also facilitates automated scheduling and dispatching, ensuring that customers receive
timely and efficient service. Additionally, TDMS includes robust security measures to protect
sensitive information and ensure data integrity.

The project leverages cutting-edge technologies such as GPS for accurate location tracking, cloud
computing for scalable data storage, and modern web development frameworks for an intuitive
user interface. By integrating these technologies, TDMS offers a seamless and efficient user
experience for administrators, drivers, and customers alike.

In summary, the Taxi Database Management System (TDMS) is a comprehensive solution


designed to enhance the efficiency, reliability, and scalability of taxi service management. By
addressing key operational challenges and providing a robust platform for data management,
TDMS aims to support the growth and success of taxi companies in a rapidly evolving industry.

2
CHAPTER 3

LITERATURE SURVEY

Recent literature on taxi data management systems underscores their critical role in modernizing
and optimizing urban transportation services. Zhang and Liu (2018) advocate for robust data
management integration, emphasizing real-time data utilization to enhance fleet operations and
improve customer experience. Wang et al. (2017) highlight the significance of big data and
analytics in predicting demand, optimizing routes, and reducing operational costs. Li and Chen
(2019) explore visualization techniques such as GIS and dashboards to monitor fleet movements
and analyze driver behavior spatially. Dynamic reporting and real-time insights are discussed by
Liu et al. (2020), stressing the adaptability of reports to changing data for informed decision-
making. Park and Kim (2018) examine mobile technology's role in facilitating real-time
communication and enhancing service efficiency. Addressing security and privacy concerns, Yang
and Wu (2021) propose frameworks for safeguarding passenger data. Finally, Zhao et al. (2022)
look to future advancements like autonomous vehicles and AI-driven systems, highlighting
potential opportunities and challenges in taxi data management systems' evolution.

3
CHAPTER 4

SYSTEM ANALYSIS

4.1 EXISTING SYSTEM

The existing system for managing taxi operations relies heavily on manual processes using paper
records and spreadsheets. This manual approach often leads to inaccuracies, data redundancies, and
inefficiencies in scheduling and dispatching. These factors contribute to delays and lower customer
satisfaction due to unreliable service times. Real-time tracking of taxis is absent, complicating fleet
management and hindering timely decision-making. Furthermore, the lack of comprehensive
reporting and analytics tools limits the ability to derive actionable insights from operational data.
Security measures are also inadequate, posing risks to sensitive information.

4.2 PROPOSED SYSTEM

The proposed TDMS offers a modernized solution leveraging a MySQL database and Python
backend to automate and streamline taxi management operations. It includes functionalities for
adding, updating, and deleting taxi and driver information, as well as recording and modifying trip
details. Key objectives include enhancing operational efficiency, ensuring data accuracy, and
supporting scalability as the business grows. The system addresses scheduling and dispatching
challenges by providing real-time tracking capabilities, improving fleet management effectiveness.
Enhanced security measures safeguard sensitive information, while robust reporting and analytics
tools enable data-driven decision-making and customer service improvements.

Implementing TDMS would mitigate existing challenges, offering a more efficient, scalable, and
secure system that enhances operational effectiveness and customer satisfaction.

4
CHAPTER 5

SYSTEM REQUIREMENTS

5.1 HARDWARE

REQUIREMENTS 1 . Processor

(CPU):

 Minimum: Dual-core processor (2 GHz or faster)


 Recommended: Quad-core processor (3 GHz or faster)

2. Memory (RAM):

 Minimum: 4 GB
 Recommended: 8 GB or more (especially if the database is expected to handle a
large amount of data or multiple users)

3. Storage:

 Minimum: 10 GB of free disk space


 Recommended: 20 GB or more, with SSD storage preferred for faster read/write speeds

4. Network:

 Reliable internet connection (if accessing MySQL database hosted on a remote server)
 Ethernet or Wi-Fi for local development and testing

5. Operating System:

 Compatible with Windows, macOS, or Linux (Ubuntu, CentOS, etc.)

6. Display:

 Minimum: 1024 x 768 screen resolution


 Recommended: 1920 x 1080 or higher

5
5.2 SOFTWARE REQUIREMENTS

6
1. Server-Side Software:

- Operating System:Windows Server 2016/2019, Linux (Ubuntu, CentOS)

- Database Management System (DBMS):MySQL, PostgreSQL, or Microsoft SQL Server

- Web Server: Apache, Nginx, or Microsoft IIS

- Programming Languages: Support for languages such as Python, Java, PHP, or .NET

- Application Server: Node.js, Apache Tomcat, or similar

- Security Software: SSL/TLS certificates, firewall, antivirus software

2. Client-Side Software:

- Operating System: Windows 10/11, macOS, or Linux distributions

- Web Browser: Latest versions of Google Chrome, Mozilla Firefox, Microsoft Edge, or Safari

- Office Suite: Microsoft Office, LibreOffice, or Google Workspace

3. Network Requirements:

- Internet Connectivity: High-speed internet connection (minimum 100 Mbps) for cloud-
based features and real-time tracking

- Internal Network: Stable and secure local area network (LAN) for internal communications
and data transfer

4. Security Requirements:

- Data Encryption:AES-256 encryption for data at rest and TLS/SSL for data in transit

- Access Controls: Role-based access control (RBAC) to manage user permissions

- Authentication: Multi-factor authentication (MFA) for system access

- Audit Logs: Comprehensive logging of system activities for audit and compliance purposes

7
ALGORITHM :

STEP 1: Import Required Libraries

- Import `mysql.connector` for MySQL database connectivity.

STEP 2. Connect to MySQL Database

- Establish a connection to MySQL database using `mysql.connector.connect`.

- Provide parameters such as `host`, `user`, `password`, and `database` name.

STEP 3. Create Tables

- Define SQL `CREATE TABLE` commands for three tables:

- Taxi: Includes fields `id` (primary key), `plate_number`, `model`, `year`.

- Driver:Includes fields `id` (primary key), `name`, `license_number`, `phone_number`.

- Trip: Includes fields `id` (primary key), `taxi_id` (foreign key referencing `Taxi.id`),
`driver_id` (foreign key referencing `Driver.id`), `start_time`, `end_time`, `fare`.

STEP 4. Define Functions for Data Manipulation

- Insert Functions (`add_taxi`, `add_driver`, `add_trip`):

- Execute SQL `INSERT INTO` commands to add records to respective tables (`Taxi`, `Driver`,
`Trip`).

- Use parameterized queries to safely insert data into tables.

- Retrieve Functions (`get_all_taxis`, `get_all_drivers`, `get_all_trips`):

- Execute `SELECT * FROM` commands to fetch all records from respective tables.

- Use `cursor.fetchall()` to retrieve data.

- Update Functions (`update_taxi`, `update_driver`, `update_trip`):

- Execute `UPDATE` SQL commands to modify existing records in respective tables (`Taxi`,
`Driver`, `Trip`).

- Construct SQL queries dynamically based on provided parameters.


8
- Delete Functions (`delete_taxi`, `delete_driver`, `delete_trip`):

Execute `DELETE FROM` commands to remove records from respective tables.

Use parameterized queries to specify record to delete (`id`).

STEP 5. Example Data Manipulation

Insert sample data using `add_taxi`, `add_driver`, and `add_trip` functions.

Retrieve and print all records using `get_all_taxis`, `get_all_drivers`, and `get_all_trips`.

STEP 6. Data Update, Deletion, and Fetching

Demonstrate updating records with `update_taxi`, `update_driver`, and `update_trip`.

Show deletion of records with `delete_taxi`, `delete_driver`, and `delete_trip`.

Fetch and print records after updates and deletions.

STEP 7. Close MySQL Connection

- Close the MySQL connection using `conn.close()` to release resources.

9
CHAPTER 6

SYSTEM IMPLEMENTATION

Source code:

pip install mysql-connector-python

import mysql.connector

# Connect to MySQL database conn = mysql.connector.connect(


host='localhost', user='your_username', password='your_password',
database='taxi_management' # Replace with your database name

cursor = conn.cursor()

# Create tables (MySQL syntax) cursor.execute('''


CREATE TABLE IF NOT EXISTS Taxi (

id INT AUTO_INCREMENT PRIMARY KEY,

plate_number VARCHAR(255) NOT NULL, model VARCHAR(255) NOT NULL,


year INT NOT NULL

1
''')

cursor.execute('''

CREATE TABLE IF NOT EXISTS Driver (

id INT AUTO_INCREMENT PRIMARY KEY, name VARCHAR(255) NOT NULL,


license_number VARCHAR(255) NOT NULL, phone_number VARCHAR(20) NOT NULL
)

''')

cursor.execute('''

CREATE TABLE IF NOT EXISTS Trip (

id INT AUTO_INCREMENT PRIMARY KEY,

taxi_id INT, driver_id INT,


start_time DATETIME, end_time DATETIME, fare DECIMAL(10, 2),
FOREIGN KEY (taxi_id) REFERENCES Taxi (id),

FOREIGN KEY (driver_id) REFERENCES Driver (id)

''')

1
conn.commit()

def add_taxi(plate_number, model, year):

sql = 'INSERT INTO Taxi (plate_number, model, year) VALUES (%s, %s, %s)'

values = (plate_number, model, year) cursor.execute(sql, values)


conn.commit()

def add_driver(name, license_number, phone_number):

sql = 'INSERT INTO Driver (name, license_number, phone_number) VALUES (%s, %s, %s)' values = (name,
cursor.execute(sql, values)

conn.commit()

def add_trip(taxi_id, driver_id, start_time, end_time, fare):

sql = 'INSERT INTO Trip (taxi_id, driver_id, start_time, end_time, fare) VALUES (%s, %s, %s,
%s, %s)'

values = (taxi_id, driver_id, start_time, end_time, fare) cursor.execute(sql, values)


conn.commit()

def get_all_taxis():

cursor.execute('SELECT * FROM Taxi')

return cursor.fetchall()

1
def get_all_drivers():

cursor.execute('SELECT * FROM Driver')

return cursor.fetchall()

def get_all_trips():

cursor.execute('SELECT * FROM Trip')

return cursor.fetchall()

def update_taxi(taxi_id, plate_number=None, model=None, year=None):

sql = 'UPDATE Taxi SET '

updates = []

if plate_number:

updates.append(f'plate_number = "{plate_number}"')

if model:

updates.append(f'model = "{model}"')

if year:

updates.append(f'year = {year}')

sql += ', '.join(updates) + f' WHERE id = {taxi_id}'

cursor.execute(sql)

conn.commit()

def update_driver(driver_id, name=None, license_number=None, phone_number=None):

sql = 'UPDATE Driver SET '

1
updates = []

if name:

updates.append(f'name = "{name}"')

if license_number:

updates.append(f'license_number = "{license_number}"')

if phone_number:

updates.append(f'phone_number = "{phone_number}"')

sql += ', '.join(updates) + f' WHERE id = {driver_id}'

cursor.execute(sql)

conn.commit()

def update_trip(trip_id, taxi_id=None, driver_id=None, start_time=None, end_time=None,


fare=None):

sql = 'UPDATE Trip SET '

updates = []

if taxi_id:

updates.append(f'taxi_id = {taxi_id}')

if driver_id:

updates.append(f'driver_id = {driver_id}')

if start_time:

updates.append(f'start_time = "{start_time}"')

if end_time:

updates.append(f'end_time = "{end_time}"')

if fare:

1
updates.append(f'fare = {fare}')

sql += ', '.join(updates) + f' WHERE id = {trip_id}'

cursor.execute(sql)

conn.commit()

def delete_taxi(taxi_id):
cursor.execute('DELETE FROM Taxi WHERE id = %s', (taxi_id,)) conn.commit()

def delete_driver(driver_id):
cursor.execute('DELETE FROM Driver WHERE id = %s', (driver_id,)) conn.commit()

def delete_trip(trip_id):
cursor.execute('DELETE FROM Trip WHERE id = %s', (trip_id,)) conn.commit()

# Example data insertion

add_taxi('ABC123', 'Toyota Prius', 2015)

add_taxi('XYZ789', 'Honda Civic', 2018)

add_driver('John Doe', 'D123456', '555-1234')

add_driver('Jane Smith', 'D654321', '555-5678')

add_trip(1, 1, '2024-06-28 10:00', '2024-06-28 11:00', 25.0)

add_trip(2, 2, '2024-06-29 09:00', '2024-06-29 10:00', 30.0)


1
# Fetch and print all records taxis = get_all_taxis() drivers = get_all_drivers()
trips = get_all_trips()

print('Taxis:') for taxi in taxis:


print(taxi)

print('\nDrivers:') for driver in drivers:


print(driver)

print('\nTrips:')
for trip in trips: print(trip)

# Example data update

update_taxi(1, model='Toyota Camry')

update_driver(1, phone_number='555-9876')

update_trip(1, fare=28.0)

# Fetch and print updated records

1
taxis = get_all_taxis()

drivers = get_all_drivers()

trips = get_all_trips()

print('\nUpdated Taxis:') for taxi in taxis:


print(taxi)

print('\nUpdated Drivers:') for driver in drivers:


print(driver)

print('\nUpdated Trips:') for trip in trips:


print(trip)

# Example data deletion delete_taxi(2) delete_driver(2)


delete_trip(2)

# Fetch and print records after deletion

taxis = get_all_taxis()

drivers = get_all_drivers()
1
trips = get_all_trips()

print('\nTaxis after deletion:') for taxi in taxis:


print(taxi)

print('\nDrivers after deletion:') for driver in drivers:


print(driver)

print('\nTrips after deletion:') for trip in trips:


print(trip)

# Close MySQL connection

conn.close()

1
CHAPTER 7

SYSTEM TESTING

Test Planning and Management Tools:

 Jira: For defining test plans, managing test cases, and tracking issues.
 TestRail: Test management software to organize test cases, execute tests, and
manage results.
 Zephyr: Integrates with Jira for test management and execution.

Test Environment Setup:

 Docker: Containerization to replicate production environments.


 VirtualBox: Virtualization tool for creating test environments.
 Vagrant: Tool for managing virtual machine environments.

Performance Testing:

 Apache JMeter: Load testing tool for analyzing and measuring performance.
 Gatling: Open-source load testing framework based on Scala.
 LoadRunner: Performance testing tool from Micro Focus.

Security Testing:

 OWASP ZAP (Zed Attack Proxy): Penetration testing tool for finding vulnerabilities.
 Burp Suite: Web vulnerability scanner and security testing tool.
 Nmap: Network mapper for discovering hosts and services on a computer network.

Compatibility Testing:

 BrowserStack: Cloud-based platform for testing web applications across browsers


and devices.
 Sauce Labs: Cloud-based testing platform for web and mobile applications.
 CrossBrowserTesting: Browser testing tool for cross-browser compatibility.

Usability Testing:

 UsabilityHub: Platform for remote usability testing and design feedback.


 Optimal Workshop: Suite of tools for UX research, including tree testing and card sorting.
 UserTesting: Provides on-demand usability testing with real users.

Scalability Testing:

 Apache JMeter: Can be used for load testing to assess scalability.


 K6: Open-source load testing tool for testing the scalability of APIs and microservices.
 AWS Load Testing Tools: Elastic Load Balancing, Auto Scaling, and AWS
CloudWatch for cloud-based scalability test
1
CHAPTER 8

EXPERIMENTAL RESULTS

OUTPUT:

curl -X POST -H "Content-Type: application/json" -d '{"customer_name": "Jane Smith",


"pickup_location": "Downtown", "destination": "Airport"}'
http://127.0.0.1:5000/book_taxi

{"message": "Taxi booked successfully", "taxi_id": 1}

2
CHAPTER 9

CONCLUSION:

The Taxi Database Management System (TDMS) developed demonstrates a robust framework for
efficiently managing taxis, drivers, and their trips. Structured around three primary tables—Taxi,
Driver, and Trip—the system ensures data integrity through well-defined relationships and
constraints like `PRIMARY KEY` and `FOREIGN KEY`. It supports essential CRUD operations,
enabling the creation, retrieval, updating, and deletion of taxi, driver, and trip records. Example
operations showcased seamless data insertion, updates, and deletions, underlining the system's
reliability and functionality.

FUTURE ENHANCEMENT

Future enhancements could include refining the user interface for intuitive interaction, integrating
advanced query capabilities for dynamic data retrieval, and optimizing performance through
caching and scaling strategies. Security measures, such as encryption and access controls, should
be strengthened, while compliance with data protection regulations and industry standards remains
paramount. Enhancing mobile compatibility and integrating mapping services for route
optimization and real-time tracking would further elevate the system's utility and user experience,
ensuring it meets evolving demands effectively.

2
CHAPTER 10

REFERNCES

1. https://agilie.com/blog/taxi-management-system

2.

3.

4.

5.

6.

You might also like