Riddhiman Saha Computer Science Final Project on Book Management System
Riddhiman Saha Computer Science Final Project on Book Management System
SESSION: 2023-24
PROJECT REPORT ON
ROLL NO : 22712737
CLASS : XII
……………………………………..
……………………………….
Teacher In-Charge Principal
……………………………………..
Practical Examiner School
Stamp
TABLE OF CONTENTS [T O C]
1. Acknowledgement 1
2. Introduction 2
3. Objective of Project 3
4. Proposed System 3
7. Initiation Phase 6
9. Pictorial Representation 7
19. Output 21
20. Testing 23
21. Conclusion 25
22. Bibliography 26
ACKNOWLEDGEMENT
I would like to express my special thanks of gratitude to my Computer Teacher “Mr Sourav
Roy” for his guidance and support which helped me immensely in making this project. Without
his guidance and encouragement, the project could not have been what it evolved to be.
I would also like to thank our Principal “Dr Maushumi” for her constant support and supervision
and for providing me with the opportunity to create my project on “Book Store Management”.
I would also like to express my gratitude to my parents and all my friends for their constant
encouragement and cooperation.
PROJECT ON Book Store Management
INTRODUCTION
In today’s era computers have become a vital component of any enterprise for giving it proper
directions and extensive control of the various activities to attain business objectives.
Computer applications have affected scientific & commercial knowledge.
In the previous ages the process of maintaining data and record seemed very difficult.
Nowadays computer is a very essential component.
The implementation of computer based Information system can be depicted as the ease in
handling and maintaining the data bank of any site.
The Book management system database effortlessly integrates all components related to a book
store. Book Store Management system mainly focuses on the activities of a bookstore such as
information on books and books sold to customers. The database flexibility , convenient features,
the maximum increase in customer service, access to accurate information make this ideal for all
sizes of Book management . The Book management system is used for analyzing the store
information, customer information and when necessary to produce reports.
OBJECTIVES OF THE PROJECT
The bookstore management system will help in maintaining the details of the books available,
customer’s details, details of the books given on rent, sales record, employee's details and many
other details
PROPOSED SYSTEM
In the past to acquire details of a particular book, customers had to go through the entire library
until they found that book.
The proposed system is helpful in various ways:
1. Books and their availability can be checked in an instant.
2. Number of books sold can be found out.
3. The price of a book and discounts available can be viewed which will help in making bills
quicker.
4. It will make the entire experience of purchasing books and maintaining records easier.
HARDWARE AND SOFTWARE REQUIREMENTS
SOFTWARE REQUIREMENTS:
I. Windows OS
II. Python
SYSTEM DEVELOPMENT LIFE CYCLE (SDLC)
A system development life cycle or SDLC is essentially a project management model. It defines
different stages that are necessary to bring a project from its initial idea or conception all the way
to deployment and later maintenance.
System Development Life Cycle (SDLC) is a conceptual model which includes policies and
procedures for developing or altering systems throughout their life cycles.
SDLC is used by analysts to develop an information system. SDLC includes the following
activities :
Requirement
Design
Implementation
Testing
Deployment
Operations
Maintenance
PHASES OF SYSTEM DEVELOPMENT LIFE CYCLE
INITIATION PHASE
The first or initiation phase of the SDLC is the project planning stage where you are gathering
business requirements from your client or stakeholders. This phase is when you evaluate the
feasibility of creating the product, revenue potential, the cost of production, the needs of the
end-users, etc.
This includes all the specifications for software, hardware, and network requirements for the
system they plan to build. This will prevent them from overdrawing funding or resources when
working at the same place as other development teams.
DESIGN PHASE
The design stage is a necessary precursor to the main developer stage.
Developers will first outline the details for the overall application, alongside specific aspects,
such as its:
User interfaces
System interfaces
Network and network requirements
Databases
They’ll typically turn the SRS document they created into a more logical structure that can later
be implemented in a programming language. Operation, training, and maintenance plans will all
be drawn up so that developers know what they need to do throughout every stage of the cycle
moving forward.
Product program code is built per the design document specifications. In theory, all of the prior
planning and outlining should make the actual development phase relatively straightforward.
Developers will follow any coding guidelines as defined by the organization and utilize different
tools such as compilers, debuggers, and interpreters.
During the testing stage, developers will go over their software with a fine-tooth comb, noting
any bugs or defects that need to be tracked, fixed, and later retested.
IMPLEMENTATION PHASE
After testing, the overall design for the software will come together. Different modules or designs will be
integrated into the primary source code through developer efforts, usually by leveraging training
environments to detect further errors or defects.
The information system will be integrated into its environment and eventually installed. After
passing this stage, the software is theoretically ready for market and may be provided to any end-
users.
Furthermore, developers are responsible for implementing any changes that the software might
need after deployment.
This can include handling residual bugs that were not able to be patched before launch or
resolving new issues that crop up due to user reports. Larger systems may require longer
maintenance stages compared to smaller systems.
DISPOSITION PHASE
The disposition activities ensure the orderly termination of the system and preserve the vital
information about the system so that some or all of the information may be reactivated in the
future if necessary. Particular emphasis is given to proper preservation of the data processed by
the system, so that the data is effectively migrated to another system or archived in accordance
with applicable records management regulations and policies, for potential future access.
SOURCE CODE
import mysql.connector
mydb=mysql.connector.connect (host="localhost", user="root", password="admin")
while True:
print("""1:Signup 2:Login""")
ch=int(input("SIGNUP/LOGIN(1,2):"))
#SIGNUP
if ch==1:
username=input("USERNAME:")
pw=input("PASSWORD:")
mycursor.execute("insert into signup values('"+username+"','"+pw+"')")
mydb.commit()
#LOGIN
elif ch==2:
username=input("USERNAME:")
mycursor.execute("select username from signup where username='"+username+"'")
pot=mycursor.fetchone()
if pot is not None:
print("VALID USERNAME!!!!!!")
pw=input("PASSWORD:")
mycursor.execute("select password from signup where password='"+pw+"'")
a=mycursor.fetchone()
if a is not None:
print("""+++++++++++++++++++++++
+++LOGIN SUCCESSFULL++++++++++++++++++++++++++""")
print("""===============================================================
=======
++++++++++++++++++++++++++ MY BOOK STORE ++++++++++++++++++++++++
+
=====================================================================
=====""")
mycursor.execute("create table if not exists Available_Books(BookName varchar(30)
primary key,Genre varchar(20),Quantity int(3),Author varchar(20),Publication varchar(30),Price
int(4))")
mycursor.execute("create table if not exists Sell_rec(CustomerName
varchar(20),PhoneNumber char(10) unique key, BookName varchar(30),Quantity int(100),Price
int(4),foreign key (BookName) references Available_Books(BookName))")
mycursor.execute("create table if not exists Staff_details(Name varchar(30), Gender
varchar(10),Age int(3), PhoneNumber char(10) unique key , Address varchar(40))")
mydb.commit()
while(True):
print("""1:Add Books
2:Delete Books
3:Search Books
4:Staff Details
5:Sell Record
6:Available Books
7:Total Income after the Latest Reset
8:Exit""")
a=int(input("Enter your choice:"))
#ADD BOOKS
if a==1:
print("All information prompted are mandatory to be filled")
book=str(input("Enter Book Name:"))
genre=str(input("Genre:"))
quantity=int(input("Enter quantity:"))
author=str(input("Enter author name:"))
publication=str(input("Enter publication house:"))
price=int(input("Enter the price:"))
mycursor.execute("select * from Available_Books where bookname='"+book+"'")
row=mycursor.fetchone()
if row is not None:
mycursor.execute("update Available_Books set
quantity=quantity+'"+str(quantity)+"' where bookname='"+book+"'")
mydb.commit
print("""++++++++++++++++++++++
++SUCCESSFULLY ADDED++
++++++++++++++++++++++""")
else:
mycursor.execute("insert into
Available_Books(bookname,genre,quantity,author,publication,price)
values('"+book+"','"+genre+"','"+str(quantity)+"','"+author+"','"+publication+"','"+str(price)+"')")
mydb.commit()
print("""++++++++++++++++++++++
++SUCCESSFULLY ADDED++
++++++++++++++++++++++""")
#DELETE BOOKS
elif a==2:
print("AVAILABLE BOOKS...")
mycursor.execute("select * from Available_Books ")
for x in mycursor:
print(x)
cusname=str(input("Enter customer name:"))
phno=int(input("Enter phone number:"))
book=str(input("Enter Book Name:"))
price=int(input("Enter the price:"))
n=int(input("Enter quantity:"))
mycursor.execute("select quantity from available_books where
bookname='"+book+"'")
lk=mycursor.fetchone()
if max(lk)<n:
print(n,"Books are not available!!!!")
else:
mycursor.execute("select bookname from available_books where
bookname='"+book+"'")
log=mycursor.fetchone()
if log is not None:
mycursor.execute("insert into Sell_rec values('"+cusname+"','"+str(phno)
+"','"+book+"','"+str(n)+"','"+str(price)+"')")
mycursor.execute("update Available_Books set quantity=quantity-'"+str(n)
+"' where BookName='"+book+"'")
mydb.commit()
print("""++++++++++++++++++++++
++BOOK HAS BEEN SOLD++
++++++++++++++++++++++""")
else:
print("BOOK IS NOT AVAILABLE!!!!!!!")
#BY BOOKNAME
if l==1:
o=input("Enter Book to search:")
mycursor.execute("select bookname from available_books where
bookname='"+o+"'")
tree=mycursor.fetchone()
if tree!=None:
print("""++++++++++++++++++++
++BOOK IS IN STOCK++
++++++++++++++++++++""")
else:
print("BOOK IS NOT IN STOCK!!!!!!!")
#BY GENRE
elif l==2:
g=input("Enter genre to search:")
mycursor.execute("select genre from available_books where genre='"+g+"'")
poll=mycursor.fetchall()
if poll is not None:
print("""++++++++++++++++++++
++BOOK IS IN STOCK++
++++++++++++++++++++""")
mycursor.execute("select * from available_books where genre='"+g+"'")
for y in mycursor:
print(y)
else:
print("BOOKS OF SUCH GENRE ARE NOT AVAILABLE!!!!!!!!!")
#STAFF DETAILS
elif a==4:
print("1:New staff entry")
print("2:Remove staff")
print("3:Existing staff details")
ch=int(input("Enter your choice:"))
#REMOVE STAFF
elif ch==2:
nm=str(input("Enter staff name to remove:"))
mycursor.execute("select name from staff_details where name='"+nm+"'")
toy=mycursor.fetchone()
if toy is not None:
mycursor.execute("delete from staff_details where name='"+nm+"'")
print("""+++++++++++++++++++++++++++++++++
++STAFF IS SUCCESSFULLY REMOVED++
+++++++++++++++++++++++++++++++++""")
mydb.commit()
else:
print("STAFF DOESNOT EXIST!!!!!!")
#SELL HISTORY
elif a==5:
print("1:Sell history details")
print("2:Reset Sell history")
ty=int(input("Enter your choice:"))
if ty==1:
mycursor.execute("select * from sell_rec")
for u in mycursor:
print(u)
if ty==2:
bb=input("Are you sure(Y/N):")
if bb=="Y":
mycursor.execute("delete from sell_rec")
mydb.commit()
elif bb=="N":
pass
#AVAILABLE BOOKS
elif a==6:
mycursor.execute("select * from available_books order by bookname")
for v in mycursor:
print(v)
else:
print("""++++++++++++++++++++
++INVALID USERNAME++
++++++++++++++++++++""")
else:
break
OUTPUT OF SOURCE CODE
= RESTART: C:\Users\Compaq\BOOKSTORE MANAGEMENT.py
1:Signup
2:Login
SIGNUP/LOGIN(1,2):1
USERNAME:"jitendra"
PASSWORD:"12345"
1:Signup
2:Login
SIGNUP/LOGIN(1,2):2
USERNAME:"jitendra"
VALID USERNAME!!!!!!
PASSWORD:"12345"
+++++++++++++++++++++++
+++LOGIN SUCCESSFULL+++
+++++++++++++++++++++++
=====================================================================
=
++++++++++++++++++++++++++ MY BOOK STORE +++++++++++++++++++++++++
=====================================================================
=====
1:Add Books
2:Delete Books
3:Search Books
4:Staff Details
5:Sell Record
6:Available Books
7:Total Income after the Latest Reset
8:Exit
Enter your choice:1
All information prompted are mandatory to be filled
Enter Book Name:"Computer Science with Python"
Genre:"Programming"
Enter quantity:10
Enter author name:"cbsepython"
Enter publication house:"cbsepython.in"
Enter the price:320
++++++++++++++++++++++
++SUCCESSFULLY ADDED++
++++++++++++++++++++++
1:Add Books
2:Delete Books
3:Search Books
4:Staff Details
5:Sell Record
6:Available Books
7:Total Income after the Latest Reset
8:Exit
Enter your choice:8
TESTING
Code-based testing involves testing out each line of code of a program to identify bugs or errors
during the software development process. Specific test cases are checked on the program to see if
it performs the functions required.
TESTING METHODS
Testing methodologies are the various strategies or approaches used to test an application to
ensure it behaves and looks as expected. These encompass everything from front to back-end
testing, including unit and system testing.
https://www.elprocus.com/
https://www.clouddefense.ai/
https://code-projects.org/
https://www.scribd.com/
All in One For Computer Science with Python Class 12