Comp SC Project 1
Comp SC Project 1
Signature of Guide
(Mustaque Ahmed)
CONTENTS
ACKNOWLEDGMENT----------------------------------04
INTRODUCTION------------------------------------------05
OBJECTIVE OF THE PROJECT------------------------06
KEY COMPONENTS OF HBMS-----------------------08
BENEFITS OF HBMS------------------------------------10
DETAILED DESCRIPTION---------------------—----12
SAMPLE CODE-------------------------------------------14
SAMPLE OUTPUT----------------------------------------18
CONCLUSION---------------------------------------------21
BIBLIOGRAPHY------------------------------------------22
ACKNOWLEDGMENT
Specific Objectives:
Room Management:
Real-time room inventory tracking.
Housekeeping and maintenance task scheduling. Room
status monitoring.
Reservation Management:
Online booking engine for direct guest bookings.
Reservation calendar for visual planning. Group
reservation handling
Regular Payment Management :
Secure payment processing through various channels
Accurate billing and invoicing
Detailed financial reporting
1.Increased Efficiency:
a) Automation of tasks: Automates routine tasks like check-ins,
check-outs, and room assignments.
b) Reduced manual errors: Minimizes human error and
ensures accuracy.
c) Streamlined operations: Simplifies complex processes and
improves overall efficiency.
Core Functionalities:
import sqlite3
from datetime import datetime
#Connect to SQLite database
Cursor = conn.cursect(hotel_booking_system.db')
#Create tables
cursor.execute(""
CREATE TABLE IF NOT EXISTS hotels ( id
INTEGER PRIMARY KEY,
name TEXT,
address TEXT,
contact_number TEXT
)
"")
cursor.execute(""
CREATE TABLE IF NOT EXISTS rooms (
id INTEGER PRIMARY KEY,
hotel_id INTEGER,
room_number TEXT,
room_type TEXT,
capacity INTEGER,
availability INTEGER,
FOREIGN KEY (hotel_id) REFERENCES hotels(id)
)
"cursor.execute(''
CREATE TABLE IF NOT EXISTS customers (
id INTEGER PRIMARY KEY,
name TEXT,
contact_number TEXT
)
"")
cursor.execute("""
CREATE TABLE IF NOT EXISTS reservations (
id INTEGER PRIMARY KEY,
customer_id INTEGER,
room_id INTEGER,
check_in_date DATE,
check_out_date DATE,
status TEXT,
FOREIGN KEY (customer_id) REFERENCES
customers(id),
FOREIGN KEY (room_id) REFERENCES rooms(id)
)
"")
import mysql.connector
#Connect to MySQL
mydb= mysql.connector.connect(
host="localhost",
user="yourusername",
password="yourpassword",
database="hotel_booking"
)
mydb.commit()
print("Room booked successfully!")
# Example usage:
# Display available rooms
display_available_rooms()
# Book a room
book_room(124, "Anita Patil", "2024-12-26", "2024-12-31")
CONCLUSION
www.scribd.com
www.slideshare.net