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

Library Management System - Doc Removed

This document contains an index and details of a python project for managing customer contact details. It includes 12 sections that describe the abstract, introduction, system requirements, feasibility study, error types, testing, maintenance, modules used, requirement analysis, coding, output, and conclusion. The project aims to create a platform for customers to provide brief contact details and for firms to easily add, delete, and view customer details in their database. It will record customer first name, last name, gender, age, address, and contact details.

Uploaded by

skgautam42066
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
33 views

Library Management System - Doc Removed

This document contains an index and details of a python project for managing customer contact details. It includes 12 sections that describe the abstract, introduction, system requirements, feasibility study, error types, testing, maintenance, modules used, requirement analysis, coding, output, and conclusion. The project aims to create a platform for customers to provide brief contact details and for firms to easily add, delete, and view customer details in their database. It will record customer first name, last name, gender, age, address, and contact details.

Uploaded by

skgautam42066
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 20

INDEX

S.NO CONTENTS Pg.NO SIGNATURE


1. ABSTRACT
2. INTRODUCTION
3. SYSTEM REQUIREMENT
4. FEASIBILITY STUDY
5. ERRORS AND ITS TYPES
6. TESTING
7. MAINTENANCE
8. MODULES USED
9. REQUIREMENT
ANALYSIS
10. CODING
11. OUTPUT
12. CONCLUSION
13. BIBLIOGRAPHY
ABSTRACT
The aim of this project is to create a platform for people to find
the contact details in an easy and better way through python.
Some of the features of this program are:

1. Customers can give short and brief information of their


contact details.
2. The firm can get instant details about the customers in
their database.
3. With this python program, the firm can easily add and
delete the contact details of their customers.
4. The main details of the customers which are needed to
be recorded through this program are their:
• First name
• Last name
• Gender
• Age
• Address
• Contact
INTRODUCTION
The computers have gained a lot of importance in the past five
decades. Most of our day-to-day jobs are being influenced by the use
of computers. Now a day, computers are used for performing almost
every function, which were performed by humans in the past. In some
areas such as science and technology, targets can’t be achieved
without the use of computers. The characteristics that make the
computer so important include its extra ordinary speed, large storage
capacity, accuracy and consistency.

Today computers play a great role in various industries and a large


number of industries are using computers for various application such
as maintaining cashbook, sales book, purchase book and other books
of accounts. Computers can also be used for the designing of various
products. Computers provide many options for the designing of
products.

The analysis of the project has been undertaken with utmost


sincerity and honesty and we will be extremely satisfied if the effort is
appreciated.
SYSTEM REQUIREMENT

HARDWARE SPECIFICATIONS
The following is the hardware specification of the system on which the software has been
developed:-

Operating System : Windows 7/10

Machine Used : i3 Processor 2.8 GHz, 2 GB RAM, 500 GB Hard Disk

SOFTWARE SPECIFICATIONS
Front End Used : Python

Backend Used : CSV File


ERRORS AND ITS TYPES
An error, some time called “A BUG” is anything in the code that
prevents a program from compiling and running correctly. There
are broadly three types of errors as follows:
1. Compile- time errors: Errors that occurs during
compilation of a program is called compile time error.
It has two types as follows:
a. Syntax error: It refers to formal rules governing the
construction of valid statements in a language.
b. Semantics error: It refers to the set of rules which give
the meaning of a statement.
2. Run time Errors: Errors that occur during the
execution of program are run time errors. These are
harder to detect errors. Some run-time error stop the
execution of program which is then called program
“Crashed”.
3. Logical Errors: Sometimes, even if you don’t
encounter any error during compiling-time and runtime,
your program does not provide the correct result. This is
because of the programmer’s mistaken analysis of the
problem he or she is trying to solve. Such errors are called
logical error.
TESTING

1. Alpha Testing: It is the most common type of testing used in


the software industry. The objective of this testing is to identify all
possible issues or defects before releasing it into the market or
to the user. It is conducted at the developer’s site.
2. Beta Testing: It is a formal type of software testing which is
carried out by the customers. It is performed in a real
environment before releasing the products into the market for the
actual end-users. It is carried out to ensure that there are no
major failures in the software or product and it satisfies the
business requirement. Beta Testing is successful when the
customer accepts the software.
3. White Box Testing: White box testing is based on the
knowledge about the internal logic of an application’s code. It is
also known as Glass box Testing. Internal Software and code
working should be known for performing this type of testing.
These tests are based on the coverage of the code statements,
branches, paths, conditions etc.
4. Black Box Testing: It is a software testing, method in which
the internal structure or design of the item to be tested is not
known to the tester. This method of testing can be applied
virtually to every level of the software testing.
MAINTENANCE
Programming maintenance refers to the modifications in the
program. After it has been completed, in order to meet changing
requirement or to take care of the errors that shown up. There
are four types of maintenance:
1. Corrective Maintenance: When the program after
compilation shows error because of some unexpected
situations, untested areas such errors are fixed up by
Corrective maintenance.
2. Adaptive Maintenance: Changes in the environment in
which an information system operates may lead to system
management. To accommodate changing needs time to
time maintenance is done and is called Adaptive
maintenance.
3. Preventive Maintenance: If possible the errors could
be anticipated before they actually occur; the
maintenance is called Preventive maintenance.
4. Perfective Maintenance: In this rapidly changing
world, information technology is the fastest growing area.
If the existing system is maintained to keep tuned with
the new features, new facilities, new capabilities, it is said
to be Perfective maintenance.
MODULES USED

DATABASE
Database is an organized collection of structured information, or data,
typically stored electronically in a computer system. ... The data can then
be easily accessed, managed, modified, updated, controlled, and
organized. Most databases use structured query language (SQL) for
writing and querying data.

DELETE DATA
As we all are aware that Python considers everything as an object, that is
why
we can easily use del to delete a dictionary in Python by deleting
elements individually. Python del keyword can also be used to delete a
key-value pair from the input dictionary values. Syntax: del dict [key]

UPDATE DATA pdateData


Update and EditThe terms "update" and "edit" are used synonymously to
make changes to text, data, images and video. ... However, "update"
refers to changes within the same version, while "upgrade" means
switching to an entirely new version (upgrades are huge updates).
import os
import csv
def newBook():
print("Add a New Book Record")
print("========================")
f=open('Library.csv','a',newline='\r\n')
s=csv.writer(f)
BookId=int(input('Enter Book Id='))
BookName=input('Enter Book Name=')
Author=input('Enter Author=')
Cost=float(input('Enter Cost='))
rec=[BookId,BookName,Author,Cost]
s.writerow(rec)
f.close()
print("Record Saved...")
input("Press any key to continue..")

def updateBook():
print("Modify a Book Record")
print("=======================")
f=open('Library.csv','r',newline='\r\n')
f1=open('temporary.csv','w',newline='\r\n')
f1=open('temporary.csv','a',newline='\r\n')
r=input('Enter Book Id of Book you want to modify=')
s=csv.reader(f)
s1=csv.writer(f1)

for rec in s:
if rec[0]==r:
print("BookId=",rec[0])
print("BookName=",rec[1])
print("Author=",rec[2])
print("Cost=",rec[3])
choice=input("Do you want to modify..?(y/n)=")
if choice=='y' or choice=='Y':
BookId=int(input('Enter New BookId='))
BookName=input('Enter new Book Name=')
Author=input('Enter Author=')
Cost=float(input('Enter Cost='))
rec=[BookId,BookName,Author,Cost]
s1.writerow(rec)
print("Record Modified...")
else:
s1.writerow(rec)
else:
s1.writerow(rec)
f.close()
f1.close()
os.remove("Library.csv")
os.rename("temporary.csv","Library.csv")

input("Press any key to continue...")

def deleteBook():
f=open('Library.csv','r',newline='\r\n')
f1=open('temporary.csv','w',newline='\r\n')
f1=open('temporary.csv','a',newline='\r\n')
r=input('Enter BookId of Book you want to delete=')
s=csv.reader(f)
s1=csv.writer(f1)

for rec in s:
if rec[0]==r:
print("BookId=",rec[0])
print("Book Name=",rec[1])
print("Author=",rec[2])
print("Cost=",rec[3])
choice=input("Do you want to delete this record(y/n)=")
if choice=='y' or choice=='Y':
pass
print("Record Deleted...")
else:
s1.writerow(rec)
else:
s1.writerow(rec)
print("No such record found...")
f.close()
f1.close()
os.remove("Library.csv")
os.rename("temporary.csv","Library.csv")

input("Press any key to continue...")

def searchBook():
print("Search a Record")
print("===================")
f=open('Library.csv','r',newline='\r\n') #Remove new line
character from output
r=input('Enter BookId you want to search=')
s=csv.reader(f)
for rec in s:
if rec[0]==r:
print("BookId=",rec[0])
print("Book Name=",rec[1])
print("Author=",rec[2])
print("Cost=",rec[3])
else:
print("No such record found...")
f.close()
input("Press any key to continue..")
def listBooks():
print("List of All Books")
print("===================")
f=open('Library.csv','r',newline='\r\n') #Remove new line
character from output
s=csv.reader(f)
for rec in s:
print(rec[0],end="\t\t")
print(rec[1],end="\t\t")
print(rec[2],end="\t\t")
print(rec[3])

f.close()
input("Press any key to continue...")

def menu():
choice=0
while choice!=6:
print("\n")
print("====================================")
print("Softare for Library Data Management")
print("====================================")
print("\n==========")
print("Main Menu")
print("==========")
print("1. Add a new Book Record")
print("2. Modify Existing Book Record")
print("3. Delete Existing Book Record")
print("4. Search a Book Record")
print("5. List of all Books")
print("6. Quit")
choice=int(input('Enter your choice'))
if choice==1:
newBook()
elif choice==2:
updateBook()
elif choice==3:
deleteBook()
elif choice==4:
searchBook()
elif choice==5:
listBooks()
elif choice==6:
print("Good Bye")
break
menu()
BIBLIOGRAPHY

Books
• Computer Science with Python – Sumita Arora

WEBSITES

• ladderpython.com
• w3schools.com

You might also like