0% found this document useful (0 votes)
13 views

Rest of the Ip Project

Uploaded by

Nabaneel Bhuyan
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)
13 views

Rest of the Ip Project

Uploaded by

Nabaneel Bhuyan
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/ 26

ACKNOWLEDGEMENT

I take the opportunity to present my vote of


thanks to all those guideposts that helped
me enlighten my way throughout this
project which has led to a successful and
satisfactory completion of this project.
I am really grateful to my project guide
Pronob Jyoti Gogoi, Nirmali Khound Baruah
and Khuman Chetia for their valuable
guidance and constant encouragement
throughout the course of the project,
without which this study would have never
been possible, who helped us and supported
us during the course of the project.
I am also thankful to the Principal and all
other Teachers of Shrimanta Shankar
Academy for their help, proper guidance
and timely suggestion during the project
period. Lastly, I am thankful to all of them
who have extended their help and support
in completing the project.
NAME: SWAPNANEEL BHUYAN

CLASS: XII(COMMERCE)

BOARD ROLL NO.:


CERTIFICATE

The project report entitled "HOTEL BOOKING


MANAGEMENT SYSTEM" submitted by
Swapnaneel Bhuyan of Shrimanta Shankar
Academy under the guidance of Mrs. Nirmali
Khound Baruah, Mr. Pronob Jyoti Gogoi and
Ms. Khuman Chetia, in partial fulfilment of
AISSE EXAMINATION 2023-2024, is a record
of the project work and the requirements
have been examined and found satisfactory.

INTERNEL EXAMINER EXTERNEL EXAMINER


DATE: DATE:
SHRIMANTA SHANKAR ACADEMY
Theoretical Background

What is Python?
Python is an open source, object-oriented
high-level programming language
developed by Guido Van Rossum in 1991 at
the National Research Institute for
Mathematics, Netherlands.
Features of Python:
 It is an interactive, interpreted language.
 It is a loosely typed object-oriented
language.
 It is a free open-source and portable
language.
 It takes less time to develop programs.
 It is extensible/extendable and highly
efficient.
 It supports GUI.
 It can be easily compatible with other
languages like C, C++ etc.
 It is used for both scientific and non-
scientific programming.
Installing Python: It can be installed by
using the website:
https://www.python.org/downloads/
Interacting with python :
Python programs can be run in two ways:

 USING COMMAND LINE WINDOW

 USING IDLE
Modules Used:
Pandas Module:
Pandas is a powerful and versatile library that
simplifies tasks of data manipulation in Python.
Pandas is built on top of the NumPy library and is
particularly well-suited for working with tabular
data, such as spreadsheets or SQL tables. Its
versatility and ease of use make it an essential
tool for data analysts, scientists, and engineers
working with structured data in Python.
What can we do using Pandas?
Pandas are generally used for data science. This
is because pandas are used in conjunction with
other libraries that are used for data science. It is
built on the top of the NumPy library which
means that a lot of structures of NumPy are used
or replicated in Pandas. The data produced by
Pandas are often used as input for plotting
functions of Matplotlib, statistical analysis in
SciPy, and machine learning algorithms in Scikit-
learn. Here is a list of things that we can do using
Pandas.
Pandas Data Structures
Pandas generally provide two data structures for
manipulating data. They are:
 a) Series
 b) DataFrame
a) Pandas Series:

A Pandas Series is a one-dimensional labelled array


capable of holding data of any type (integer, string,
float, python objects, etc.). The axis labels are
collectively called indexes.

Pandas Series is nothing but a column in an Excel


sheet. Labels need not be unique but must be a
hashable type. The object supports both integer and
label-based indexing and provides a host of methods
for performing operations involving the index.

Example of Series:

b) Pandas Dataframe:

Pandas DataFrame is a two-dimensional, size-mutable,


potentially heterogeneous tabular data structure with
labelled axes (rows and columns). A DataFrame is a
two-dimensional data structure, i.e., data is aligned in a
tabular fashion in rows and columns. Pandas
DataFrame consists of three principal components: the
data, rows, and columns.
The structure of a DataFrame resembles a spreadsheet or
relational database table, featuring rows and columns. Each
column typically represents a variable, and each row
corresponds to an observation or individual data point. This
organization allows for easy indexing, referencing, and
manipulation of data, making it an ideal choice for diverse
datasets of varying complexity.

Illustration:

 Column Label/Header: The top row contains column


labels or headers.
 Index Label: The leftmost column contains index labels.
 Row Index: Represents individual rows.
 Column: Represents individual columns.
 Element/Value/Entry: Represents individual data points.

Pandas, a powerful data manipulation library in Python,


enhances the capabilities of DataFrames by providing
additional functionalities. It enables the handling of missing
data, reshaping of data structures, merging of datasets, and
much more. This rich set of tools makes pandas DataFrames an
indispensable tool for data scientists, analysts, and researchers
working on a diverse range of projects, from business analytics
to machine learning.
4.2.2 Matplotlib Module:
Matplotlib is an amazing visualization library in Python
for 2D plots of arrays. Matplotlib is a multi-platform
data visualization library built on NumPy arrays and
designed to work with the broader SciPy stack. It was
introduced by John Hunter in the year 2002. One of the
greatest benefits of visualization is that it allows us
visual access to huge amounts of data in easily
digestible visuals. Matplotlib consists of several plots
like line, bar, scatter, histogram, etc.

To install Matplotlib:

Types of Matplotlib: Matplotlib comes with a wide


variety of plots. Plots help to understand trends, and
patterns, and to make correlations. They're typically
instruments for reasoning about quantitative
information. Some of the sample plots are covered
here.

a) Matplotlib Line Plot

b) Matplotlib Bar Plot

c) Matplotlib Histograms Plot


a) Matplotlib Line Plot: By importing the matplotlib
module, defines x and y values for a plot. Python plots
the data using the plot() function and it helps to display
the plot by using the show() function. The plot() creates
a line plot by connecting the points defined by x and y
values.

b) Matplotlib Bar Plot: By using matplotlib library in


Python, it allows us to access the functions and classes
provided by the library for plotting. There are two lists x
and y are defined. This function creates a bar plot by
taking x-axis and y-axis values as arguments and
generates the bar plot based on those values.
c) Matplotlib Histograms Plot
The Matplotlib module is used to create a histogram
plot. This plot visually represents the distribution of
data by dividing it into bins and counting the
occurrences within each bin. The hist() function is used
to create the histogram, while the show() function
displays the plot.

4.2.3 CSV Module


A CSV (Comma-Separated Values) file is a simple text
file format used to store tabular data. It's commonly
used for data exchange between different applications
and databases.

Key characteristics of CSV files:


 Tabular format: Data is organized in rows and columns.
 Comma-separated values: Each data field within a row
is separated by a comma.
 Newline-separated rows: Each row of data is separated
by a newline character.
Creating a CSV file:
1. Choose a text editor: Select a text editor like Notepad
or a more advanced code editor.
2. Create a new file: Open a new file in the text editor.
3. Enter data: Input the data you want to store in the CSV
format, separating fields with commas and rows with
newlines.
Example:

Name,Age,City
Alice,25,New York
Bob,30,Los Angeles
Importing and Exporting CSV files:
Many applications, including spreadsheet software (like
Microsoft Excel) and programming languages (like
Python), can import and export data in CSV format. This
makes CSV files a versatile format for data storage and
exchange.

To contain, separating each value with a comma and


each row with a new line. Save the file with the
extension .csv. You can open the file using MS Excel or
another spreadsheet program. It will create the table of
similar data.
Consider the following CSV file named "emp.csv" saved in
the E: Drive

empid ename doj


101 Sachin Bhardwaj 12-01-2012
102 Vinod Verma 15-01-2012
103 Anand Ganesh 05-09-2007

Importing of CSV Files

pd.read_csv() method is used to read a .csv file.

Code:

import pandas as pd
df = pd.read_csv("E:\\emp.csv")
print(df)

Output:

empid ename doj


0 101 Sachin Bhardwaj 12-01-2012
1 102 Vinod Verma 15-01-2012
2 103 Anand Ganesh 05-09-2007

Exporting Data from DataFrame to CSV File

To export a DataFrame into a CSV file, we create a DataFrame, say df1.

Use the following method:

dataframe.to_csv("E:\\dataframe1.csv")

This method exports DataFrame df1 into a CSV file named dataframe1.csv.

NOTE: DataFrame1 will get created while using to_csv()


Code:
import pandas as pd
D = [{'Name': 'Sachin', 'SirName': 'Bhardwaj'},
{'Name': 'Vinod', 'SirName': 'Verma'},
{'Name': 'Rajesh', 'SirName': 'Mishra'}]
df1 = pd.DataFrame(D)
df1.to_csv('Dataframe1.csv')

Output:

Name SirName
0 Sachin Bhardwaj
1 Vinod Verma
2 Rajesh Mishra
4.3 What is a Database?
A database is a structured collection of information related to a specific
topic or purpose. It's like a digital filing cabinet, where you can store and
retrieve data efficiently.

Key Components of a Database:

 Tables: Tables are the fundamental building blocks of a database.


They organize data into rows (records) and columns (fields). Each
row represents a single record, and each column represents a
specific attribute of that record.
 Fields: Fields are the individual categories of data within a table.
For example, in a "Customers" table, fields might include "Customer
ID," "Name," "Address," and "Phone Number."
 Records: Records are the individual rows of data in a table. Each
record represents a specific instance or entry, such as a particular
customer or product.
 Primary Key: A primary key is a unique identifier for each record in
a table. It ensures that each record is distinct and can be easily
referenced.
 Foreign Key: A foreign key is a field in one table that references
the primary key of another table. This establishes relationships
between tables.

Database Management Systems (DBMS):

DBMS software is used to manage and manipulate databases. Popular


DBMS examples include:

 MySQL: A widely-used open-source database system.


 Oracle Database: A comprehensive database system for
enterprise applications.
 Microsoft SQL Server: A relational database management system
developed by Microsoft.
 PostgreSQL: A powerful open-source object-relational database
system.
 SQLite: A lightweight, embedded database system commonly used
in mobile applications and smaller-scale projects.

By understanding the basics of databases and utilizing DBMS software,


you can effectively store, manage, and retrieve data to support various
applications and decision-making processes.
Role of RDBMS Application Program
A computer database operates like an electronic filing system,
offering numerous ways to cross-reference and organize data.
It can handle various tasks, such as managing business
inventory, accounting, and filing, and can generate reports
based on the stored information.

A Database Management System (DBMS) is a software package


used to manage and manipulate databases. Popular DBMS
examples include MS SQL Server, MS Access, Oracle, Ingres,
and Sybase.

Key Capabilities of a DBMS:

 Data Manipulation:
o Creating tables
o Adding, deleting, and modifying records
o Retrieving data selectively or collectively
 Data Organization:
o Sorting and indexing data for efficient retrieval
 Report Generation:
o Producing standardized or customized reports based on the
stored data
 Data Calculation:
o Performing mathematical calculations on the stored data
 Data Integrity:
o Ensuring data accuracy and consistency
 Database Use:
o Managing and optimizing database usage

By employing a DBMS, organizations can effectively manage


their data, improve decision-making processes, and streamline
operations.
DBMS (Database Management System)

A Database Management System (DBMS) is a software


application that interacts with a database. It allows users to
create, modify, retrieve, update, and delete data within a
database. The DBMS acts as an intermediary between the user
and the database, interpreting user queries and executing the
necessary operations to retrieve or manipulate data.

Key Functions of a DBMS:

 Data Definition: Defining the structure of the database,


including creating tables, specifying data types, and
defining relationships between tables.
 Data Manipulation: Inserting, updating, deleting, and
retrieving data from the database.
 Data Querying: Retrieving specific data from the
database using SQL queries.
 Data Security: Implementing security measures to
protect the database from unauthorized access.
 Data Integrity: Ensuring the accuracy and consistency of
data within the database.
 Data Recovery: Restoring the database to a previous
state in case of data loss or corruption.

MySQL

MySQL is a popular open-source relational database


management system. It is widely used for web applications,
content management systems, and other
1
database-driven applications.

MySQL: A Database Management System


What is a Database?
A database is a structured collection of data. It can be anything
from a simple shopping list to a complex corporate network. To
manage and access this data, we use a database management
system (DBMS).

MySQL is a popular open-source relational database


management system. It's used to store, retrieve, and manage
data efficiently.
Key Features of MySQL:
 Relational Database: MySQL organizes data into tables, with rows
representing records and columns representing fields.
 SQL-based: MySQL uses Structured Query Language (SQL) to interact with
the database. SQL is a standard language for managing relational
databases.
 Open Source: MySQL is freely available and can be customized to specific
needs.
 Scalability: It can handle small to large databases, making it suitable for
various applications.
 Performance: It offers efficient data retrieval and manipulation.
 Security: MySQL provides robust security features to protect data.
Why Use MySQL?
 Simplicity: MySQL is relatively easy to learn and use, making it accessible
to developers of all levels.
 Flexibility: It can be used with a variety of programming languages and
platforms.
 Cost-Effective: As an open-source solution, MySQL is free to use.
 Reliability: It is a stable and reliable database system.
In summary, MySQL is a powerful and versatile database
management system that has become a popular choice for
many applications. It offers a robust and efficient way to
manage and store data, making it a valuable tool for
developers and organizations alike.
SOURCE CODE
OUTPUT

Menu :

PRESS 1: ADD A NEW ROOM

PRESS 2: SHOW ALL ROOMS


PRESS 3: SHOW ALL VACANT ROOM

PRESS 4: SHOW ALL OCCUPIED ROOM

PRESS 5: BOOK A ROOM


PRESS 6: SHOW CHART

PRESS 7: EXIT
System Implementation

The Hardware used:


 Intel Pentium/Celeron or above at
Client/Server end.
 128 MB RAM and above with a minimum of
4GB HDD space (for Database) is desirable.
Standard I/O devices like Keyboard and
Mouse etc.
 Printer is needed for hard-copy reports.
 Local Area Networks (LAN) is required for
Client Server Installation.
The software used:
 Microsoft Windows 7/8/10/11 as Operating
System.
 Python 3.7.2 as Front-end Development
environment.
 MySQL as Back-end Server with Database for
testing.
 MySQL. Connector to connect Python module
with Database.
 MS-Word for documentation.
 MS-Excel for CSV files.

OBJECTIVES OF THE PROJECT

The objective of this project is to create a Hotel


Booking Management System to streamline
managing hotel reservations. This system aims to
provide a user-friendly platform for handling
bookings, customer information, room
availability, and billing efficiently.
Key goals include:
 Automate Booking Process: Allow
customers to book rooms online, check
availability, and receive instant
confirmations.
 Manage Customer Data: Store and
manage customer details efficiently for easy
retrieval and updates for future bookings.
 Optimize Room Allocation: Track room
availability in real-time to optimize room
assignments and prevent overbooking.
 Enhance Administrative Efficiency:
Provide tools for hotel staff to manage
bookings, generate reports, handle billing,
and perform administrative tasks accurately.
 Improve Customer Experience: Offer a
seamless booking experience with options for
special requests, package deals, and loyalty
rewards.
 Ensure Data Security: Implement robust
security measures to protect customer
information and transaction details.
 Facilitate Reporting and Analysis:
Generate detailed reports on booking trends,
occupancy rates, and revenue for strategic
planning.
By achieving these objectives, the system will
improve operational efficiency, enhance
customer satisfaction, and increase hotel
profitability.

You might also like