MINI PROJECT
8CSGC3171 : NOSQL database with MONGODB Lab
Topic : Hotel Management System
Submitted by
1. Kiran K Shettar 22DBCAD032
2. Jibran Pasha 22DBCAD028
Under the Guidance of
Dr. Janarthanam S
Associate Professor
School of Science and Computer Studies
2022-25 VI Semester
1
CERTIFICATE
This is to certify that the Mini Project titled Lab Device
Management System Is done by Mr Kiran K Shettar bearing
University Register Number 22DBCAD032 and is being
submitted in partial fulfillment for the course NOSQL database
with MONGODB Lab course code 8CSGC3171 as per CMR
University.
Faculty Coordinator Program Coordinator
2
Table of content
S. No. Section Title PageNo.
1 Introduction 4
2 About MongoDB 5
3 Abstract Code 6
4 Operations using Powershell 7-12
5 Operations using MongoDB 13-14
6 Atlas 15-18
7 Conclusion 19
8 Bibliography 20
3
Introduction
Hotel Management System - Mini Project (MongoDB)
The Hotel Management System (HMS) is a database-driven
project built using MongoDB to efficiently store and manage
data related to hotel operations. This system is designed to
handle various essential hotel management functionalities, such
as guest bookings, room availability, staff management, and
payment processing, using a NoSQL database.
Key Features:
1. Room Management: The system allows for the storage and
management of room information, including room type
(Single, Double, Suite), availability, pricing, and status. This
allows hotel staff to easily check and update room details.
2. Guest Management: Guest information such as name,
contact details, ID proof, and booking history are stored
securely in the database. This enables easy retrieval and
management of guest data for check-ins and check-outs.
3. Booking Management: The database tracks room bookings
made by guests, including booking dates, status (Confirmed,
Checked-In, Checked-Out), and payment details. This
ensures efficient booking management and helps track guest
stays.
4. Staff Management: Staff information is stored in the system,
including roles, personal details, and working shifts. The
database allows hotel management to efficiently organize
and access staff data.
5. Booking History and Reporting: The system stores detailed
booking history for every guest, enabling easy generation of
reports for analysis, such as booking trends, room
occupancy, and revenue generation.
4
About MongoDb
MongoDB is a popular open-source NoSQL database that stores
data in a flexible, document-oriented format. Instead of using
tables and rows like traditional relational databases, MongoDB
stores data as BSON (Binary JSON) documents within
collections. This makes it especially well-suited for projects where
data structures can vary — such as storing hardware
configurations for different desktops.
Why MongoDB for Desktop Configuration Management?
In this project, MongoDB is used to manage and store detailed
configuration data of desktops used in a lab or organizational
environment. Each desktop may have different hardware
specifications such as processor type, RAM, hard disk capacity,
graphics card, operating system, and installed software.
MongoDB’s schema-less design allows us to store these varying
configurations easily without having to predefine a rigid schema.
Key Benefits for Our Use Case:
Flexible Data Structure: Each desktop entry can have
different fields based on available components or
requirements (e.g., some systems may have dedicated
GPUs, others may not).
Easy to Scale: As more desktop systems are added or
updated, MongoDB handles the growing dataset
efficiently.
Fast Querying: MongoDB allows fast retrieval of
specific configuration data, such as searching for
desktops with more than 8GB RAM or a specific
processor model.
Embedded Documents: MongoDB supports nested
fields, which is useful for grouping hardware
specifications logically under categories like CPU,
Memory, Storage, etc.
5
Abstract
This mini-project presents a Hotel Management System
developed using MongoDB, a NoSQL database known for its
high scalability and flexible schema design. The system simulates
the core functionalities of a hotel’s data handling process by
modeling real-world entities such as Rooms, Guests, Bookings,
and Staff into separate MongoDB collections.
Each entity contains relevant fields and is interconnected using
embedded documents or references, effectively mimicking
relationships found in relational databases. The project
showcases how MongoDB can manage complex datasets
without rigid schemas, making it ideal for dynamic data
environments.
Key features include:
Inserting and querying large volumes of sample data.
Performing complex aggregations (e.g., total revenue, guest
frequency).
Creating indexes to optimize performance.
Simulating realistic booking scenarios with relationships
between guests, rooms, and staff.
This project aims to give learners practical exposure to
MongoDB’s document-oriented design and querying
mechanisms, helping them understand how to apply these skills
in real-world applications like hotel or property management
systems.
6
Code
Step 1: Open MongoDB Shell
Open a new terminal and run:
Mongosh
Step 2: Switch to or create the database
7
Step 3: Insert the data into a collection
8
9
Upload Local DB to MongoDB Atlas
Step 1. Create a MongoDB Atlas account (if not already)
Go to: [Link]
Sign up/log in
Click "Build a Database"
Choose Free (Shared
Cluster)
Step 2. Create a Cluster
Choose a cloud provider (AWS, GCP, Azure)
Select a region close you
Click Create Cluster
10
Step 3. Set up Database Access
Click Database Access > Add New Database User
Set a username and password (save it!)
Role: Choose Atlas Admin (for full access)
Step 4. Add IP Whitelist
Go to Network Access > Add IP Address
Use: ○ [Link]/0 to allow all IPs (or your own IP only)
Step 5. Add User
Step 6 Export Your Local Database
Open terminal and run:
mongodump --db=CollegeManagement --out=collegemanagement_backup
This creates a folder named labdevices_backup/ with your data.
Step 7. Upload to MongoDB Atlas
Use mongorestore with the Atlas URI: mongosh
"mongodb+srv://[Link]/" --apiVersion 1 --username
hotel-management-system
11
Operations using PowerShell
1. Create (Insert)
2. Read (Find)
13
3. Update
4. Delete
14
Operations using MongoDB Atlas
1. Create (Insert)
2. Read (Find)
15
3. Update
Creating Indexes
MongoDB Atlas UI
1. Go to Indexes Tab → Click Create Index
2. Select Field Name & Index Type → Click Create Index
16
Query to Test the Index
status of all indexes
17
Run Aggregation Queries in MongoDB Atlas
Select Your Database & Collection
Choose your database (e.g., hotel-management-system).
Click on the collection (e.g., bookings, guests, rooms, etc.)
Click on "Aggregations" Tab
At the top of the collection page, you'll see tabs like:
Documents | Aggregations | Schema | Indexes | ...
18
Conclusion
The College Student Management System project using
MongoDB effectively demonstrates how a NoSQL database can
be utilized to manage and organize student-related data in a
flexible and scalable way. By modeling entities such as students,
courses, faculties, and enrollments, the system supports key
academic operations like course registration, student
performance tracking, and faculty assignment.
MongoDB’s document-based structure makes it easier to store
diverse student profiles, course data, and attendance records
without rigid schemas, allowing for future scalability and
customization. The use of aggregation queries, indexing, and
efficient data modeling enabled fast and meaningful insights into
student performance, department analytics, and resource
utilization.
Overall, this project highlights MongoDB's capabilities in
creating a responsive and well-structured backend for education-
based applications, laying the groundwork for more advanced
systems including web portals, dashboards, and AI-driven
academic insights.
19
Bibliography
1. MongoDB Inc. (n.d.). MongoDB Documentation. Retrieved
from [Link]
2. Personal Instruction by Dr. Janarthanam S, NOSQL
database with MONGODB Lab. CMR University,
2025.
20