TABLE OF CONTENT (T O C)
S.NO TOPIC PA
GE
01 ACKNOWLEDGEMENT 01
02 INTRODUCTION 02
03 OBJECTIVES OF THE PROJECT 03
04 PROPOSED SYSTEM 04
05 SYSTEM DEVELOPMENT LIFE CYCLE (SDLC) 06
06 SOURCE CODE 07
07 OUTPUT 15
08 HARDWARE AND SOFTWARE REQUIREMENTS 24
09 BIBLIOGRAPHY 25
ACKNOWLEDGEMENT
I would like to extend my sincere gratitude to all individuals and
organizations that played a role in the successful completion of my Library
Management System project.
First, I would like to thank my project supervisor Ms. Raja Rajeswari, for
her exceptional guidance and support throughout this project. Your expertise in the
field of computer science was invaluable in shaping my understanding of library
systems and their complexities. Your constructive feedback at each stage of
development encouraged me to refine my approach and strive for excellence.
I would also like to express my appreciation to my classmates for their
camaraderie and support. The collaborative environment we fostered allowed for
productive discussions, brainstorming sessions, and mutual encouragement
A special note of thanks goes to the library staff Ms.Uma. Your willingness
to share your practical experiences and challenges in library management provided
essential context for this project. The insights you offered about user needs,
cataloging processes, and inventory management were instrumental in guiding my
development choices.
Finally, I would like to express my heartfelt gratitude to my family for their
unwavering support and encouragement. Your belief in my abilities and constant
motivation helped me to stay focused and overcome the challenges I faced during
this journey. Thank you for being my pillars of strength.This project is a collective
effort, and I am deeply appreciative of everyone who contributed to its realization .
PROJECT ON LIBRARY MANAGEMENT SYSTEM
INTRODUCTION
The Library Management System (LMS) is designed to revolutionize how
libraries operate in the digital age. By automating essential functions, this system
aims to improve the efficiency and accessibility of library resources for users and
staff alike.
Importance of Automation
In an era where technology plays a critical role in everyday life, libraries
must adapt to meet user expectations for quick and efficient access to information.
This project seeks to address these challenges by developing a comprehensive
LMS that automates tasks such as book cataloging, user registration, and
transaction management.
Goals of the System
The LMS is envisioned as a user-friendly platform that not only streamlines
library operations but also enhances the user experience. With features designed
for both patrons and librarians, the system will facilitate smoother interactions and
develop a easy book registration methods.
OBJECTIVES OF THE PROJECT
1. Automation of Library Operations
Streamlining Processes: Automate key library functions such as book
cataloging, user registration, and lending/returning of books. This will
significantly reduce manual workloads and minimize human error, allowing
staff to focus on more critical tasks.
2. Enhanced User Experience
User-Friendly Interface: Develop an intuitive interface that allows
users to easily search for books, manage their accounts, and navigate the
system. By enhancing usability, we aim to increase user engagement and
satisfaction.
4. Comprehensive Reporting Capabilities
Data-Driven Decision Making: Provide librarians with robust
reporting tools that allow them to generate insights on user activity, book
availability. These reports will facilitate informed decision-making and
improve overall library management.
PROPOSED SYSTEM
Core Features
The proposed Library Management System will include the following key
features:
User Registration and Authentication
o A secure module for users to create accounts and log in, ensuring that
only authorized individuals can access specific functionalities.
Book Cataloging
o An automated process for librarians to add, update, and remove books
from the library database, including categorization by genre and
assignment of unique identification numbers.
Borrowing and Returning System
o A streamlined procedure for users to borrow and return books,
including due date assignments and notifications for overdue items.
SYSTEM DEVELOPMENT LIFE CYCLE (SDLC)
Overview of SDLC
The System Development Life Cycle (SDLC) provides a structured framework for
developing information systems. The following phases are essential for the
successful completion of the Library Management System:
1. Requirement Analysis
o Collaborate with stakeholders to gather detailed requirements through
interviews, surveys, and observation. Understanding user needs is
crucial for a successful implementation.
2. Design
o Develop detailed design specifications, including database schemas
and user interface mockups. This phase serves as a blueprint for the
development process.
3. Implementation
o Translate design specifications into functional code. Developers will
utilize appropriate programming languages and frameworks to bring
the system to life.
4. Maintenance
o Provide ongoing support and updates to the system post-deployment.
Address any bugs or issues and incorporate user feedback to enhance
functionality.
SOURCE CODE
Create a Python project of a library Management System
PYTHON CODE:
CODE FOR WELCOME MESSAGE:
def print_design_no_alignment():
# Text lines for the design
print("****************************************************")
print("****************************************************")
print("****************************************************")
print(" WELCOME TO THE LIBRARY ")
print(" LIBRARY MANAGEMENT SYSTEM PROJECT ")
print("****************************************************")
print("****************************************************")
print("****************************************************")
print(" THIS PROJECT IS CREATED BY: ")
print(" C.A. DHANISH, T.S. PAVISAANTH, S.V. KAMALESH ")
print(" THANGAM WORLD SCHOOL ")
print("****************************************************")
print("****************************************************")
print("****************************************************")
# Run the function to display the design
print_design_no_alignment()
CODE FOR PYTHON-MYSQL CONNECTIVITY:
import mysql.connector
# Function to establish connection to MySQL database
def connect_db():
return mysql.connector.connect(
host="localhost",
user="root", # MySQL username
password="12345", # MySQL password
database="library_db")
CODE TO ADD A NEW BOOK:
# Function to add a new book
def add_book(title, author):
db = connect_db()
cursor = db.cursor()
cursor.execute("INSERT INTO books (title, author) VALUES (%s, %s)",
(title, author))
db.commit()
cursor.close()
db.close()
print("Book added successfully.")
CODE TO VIEW ALL BOOKS:
# Function to view all books
def view_books():
db = connect_db()
cursor = db.cursor()
cursor.execute("SELECT * FROM books")
result = cursor.fetchall()
for row in result:
print(f"ID: {row[0]}, Title: {row[1]}, Author: {row[2]}, Status:
{row[3]}")
cursor.close()
db.close()
CODE TO BORROW A BOOK:
# Function to borrow a book
def borrow_book(borrower_name, book_id):
db = connect_db()
cursor = db.cursor()
# Check if the book is available
cursor.execute("SELECT status FROM books WHERE book_id = %s",
(book_id,))
result = cursor.fetchone()
if result and result[0] == 'available':
cursor.execute("INSERT INTO borrowers (name, book_id) VALUES (%s,
%s)", (borrower_name, book_id))
cursor.execute("UPDATE books SET status = 'borrowed' WHERE
book_id = %s", (book_id,))
db.commit()
print(f"{borrower_name} borrowed book ID {book_id}.")
else:
print("Book is not available for borrowing.")
cursor.close()
db.close()
CODE TO RETURN A BOOK:
# Function to return a book
def return_book(book_id):
db = connect_db()
cursor = db.cursor()
# Check if the book is borrowed
cursor.execute("SELECT status FROM books WHERE book_id = %s",
(book_id,))
result = cursor.fetchone()
if result and result[0] == 'borrowed':
cursor.execute("DELETE FROM borrowers WHERE book_id = %s",
(book_id,))
cursor.execute("UPDATE books SET status = 'available' WHERE
book_id = %s", (book_id,))
db.commit()
print(f"Book ID {book_id} returned.")
else:
print("Book is not borrowed.")
cursor.close()
db.close()
CODE FOR A MENU DRIVEN FOR LMS:
# Main menu for library management system
def main():
while True:
print("\nLibrary Management System")
print("1. Add Book")
print("2. View Books")
print("3. Borrow Book")
print("4. Return Book")
print("5. Exit")
choice = input("Enter your choice: ")
if choice == '1':
title = input("Enter book title: ")
author = input("Enter book author: ")
add_book(title, author)
elif choice == '2':
view_books()
elif choice == '3':
borrower_name = input("Enter borrower name: ")
book_id = input("Enter book ID to borrow: ")
borrow_book(borrower_name, book_id)
elif choice == '4':
book_id = input("Enter book ID to return: ")
return_book(book_id)
elif choice == '5':
print("Exiting the system...")
break
else:
print("Invalid choice! Please try again.")
if __name__ == "__main__":
main()
Mysql :
DATABASE NAME: library_db
TABLE NAMES: books (1) , borrowers(2)
Description of the tables:
OUTPUT
WELCOME MESSAGE:
#ADD BOOKS
#SUCESSFULLY SAVED TO DATABASE
BOOK BORROWING:
#THE BOOK IS BORROWED AND STATUS OF BOOK
CHANGED SUCCESSFULLY
#THE BORROWER NAME AND BOOK ID IS SAVED IN TABLE
‘BORROWER’
#RETURNING A BOOK
#THE BOOK IS RETURNED AND STATUS OF BOOK
CHANGED SUCCESSFULLY
#EXITING THE PROGRAM
HARDWARE REQUIREMENTS
1.OPERATING SYSTEM : WINDOWS 7 AND ABOVE
2. PROCESSOR : PENTIUM(ANY) OR AMD
ATHALON
3. RAM : 512MB+
4. Hard disk : SATA 40 GB OR ABOVE
5. MONITOR 14.1 or 15 -17 inch
6. Key board and mouse
7. Printer : (if print is required – [Hard copy])
SOFTWARE REQUIREMENTS:
• Windows OS
• Python
• mysql
BIBLIOGRAPHY
Computer science With Python - Class XII AND CLASS XI By :
Sumita Arora
All in one
Sura’s computer science
Python training guide
***