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

Certificate: Internal Examiner External Examiner

Project tile for record purpose

Uploaded by

thankachalam844
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
26 views

Certificate: Internal Examiner External Examiner

Project tile for record purpose

Uploaded by

thankachalam844
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 13

CERTIFICATE

This is to certify that RISHABH TIWARI.P has


successfully completed Computer Science Project
towards partial completion of Practical examination
of AISSCE 2022-23 as prescribed by CBSE.

INTERNAL EXAMINER EXTERNAL EXAMINER


Acknowledgement

I wish to express my deep gratitude and sincere thanks to all


my teachers for encouragement and the management for
providing all facilities to successfully complete the project work.

I extend my sincere thanks to my Computer Science teacher


Mrs. Manicka Sankari , whose valuable guidance helped to
successfully complete the project.

I extend my gratitude to my parents and classmates for their


valuable support and time.
Introduction:

As part of our Class 12 Computer Science project, we are excited


to present a solution to a common challenge faced by educational
institutions—the Library Management System (LMS). In an era
where digital efficiency is crucial, our project focuses on using
Python programming language and MySQL database to create a
simple and user-friendly platform for managing the diverse array
of resources in a school library.

Objective:

The primary goal of our Library Management System is to Ease


the processes associated with cataloging, tracking, and accessing
library resources. By integrating python and mysql, we aim to
deliver a solution that not only meets the immediate needs of our
educational environment but also serves as a model for efficient
resource management in educational institutions.

Features:

The primary features of our Library management system are

❖ Adding and maintaining records of books in a library


❖ Issue a book and maintain records of issued books in library
❖ Return a book and maintain record of returned books

Software:
This Library management system project is made using python
and Mysql database to maintain data .

Python is a versatile and powerful programming language with a


wide range of features that contribute to its popularity and
usability. A high level object oriented programming language
known for its simplicity and easy learning curve.

MySQL is a popular open-source relational database


management system (RDBMS) that provides a robust and scalable
platform for storing, managing, and retrieving data.MySQL is
designed to handle large datasets and scale efficiently.

This project incorporates the fundamental knowledge and


features of mysql and python and uses them to create a simple
and efficient Library management system .

Interface between python and mysql :


Python and mysql can be interfaced using a python module
named mysql.connector it is a simple yet a powerful tool to
connect python and mysql .

It efficiently and flawlessly creates a connection between our


python program and the sql database and lets us execute all the
fundamental commands of the sql database right from our python
program.

Using this module we can create, retrieve and modify data from
our python interface .

Source code:
import mysql.connector
mydb = mysql.connector.connect(
host = "localhost",
user = "root",
password = "root",
database = "register"
)

def addbook():
bname = input("Enter book name: ")
bcode = input("Enter book code:")
total = input("Total books:")
sub = input("Enter subject:")
data = (bname,bcode,total,sub)
sql = "insert into books(bname,bcode,total,subject)
values(%s,%s,%s,%s)"
c = mydb.cursor()
c.execute(sql,data)
mydb.commit()
print(".............")
print("Data entered successfully")
main()

def issueb():
name = input("Enter name:")
rno = input("Enter rno:")
code = input("Enter book code:")
date = input("Enter date:")
sql = "insert into issue(name,regno,bcode,idate) values(%s,
%s,%s,%s)"
data =(name,rno,code,date)
c = mydb.cursor()
c.execute(sql,data)
mydb.commit()
print("...............")
print("Book issued to :",name)
main()
bookup(code,-1)

def submitb():
name = input("Enter name:")
regno = input("Enter rno:")
code = input("Enter book code:")
sdate = input("Enter date:")
sql = "insert into submit(name,regno,bcode,sdate)
values(%s,%s,%s,%s)"
data = (name,regno,code,sdate)
c = mydb.cursor()
c.execute(sql,data)
mydb.commit()
print("...............")
print("Book submitted from :",name)
bookup(code,1)

def bookup(co,u):
sql = "select TOTAL from books where BCODE = %s"
data = (co,)
c = mydb.cursor()
c.execute(sql,data)
myresult = c.fetchone()
t = myresult[0] + u
sql = "update books set TOTAL = %s where BCODE = %s"
d = (t,co)
c.execute(sql,d)
mydb.commit()
main()

def dbook():
ac = input("Enter book code:")
sql = "delete from books where BCODE = %s"
data = (ac,)
c = mydb.cursor()
c.execute(sql,data)
mydb.commit()
main()

def dispbook():
sql = "select * from books"
c = mydb.cursor()
c.execute(sql)
myresult = c.fetchall()
for i in myresult:
print("Book name:",i[0])
print("Book code:",i[1])
print("Total:",i[2])
print("................")
main()

def main():
print("""............LIBRARY MANAGEMENT.............
1.Add book
2.Issue book
3.Submit book
4.Delete book
5.Display book
""")
choice = input("Enter task no:")
print("............................")
if(choice == '1'):
addbook()
elif(choice == '2'):
issueb()
elif(choice == '3'):
submitb()
elif(choice == '4'):
dbook()
elif(choice == '5'):
dispbook()
else:
print("wrong choice")
main()

def password():
import random
ps = random.randint(000000,100000)

user = input("Enter Username: ")


print("Your password is:",ps)

verify = input("Enter password:")

if verify == str(ps):
main()
else:
verify != str(ps)
print("wrong password")
password()

password()

Output:
Conclusion:

The combination of computer science principles and


programming languages like Python and SQL opens up a vast
array of possibilities for creating practical and impactful
applications that can address real-life problems. Let's explore how
the principles used in a Library Management System (LMS) can be
extended to solve problems in different domains.The versatility of
Python and the efficiency of SQL databases make them powerful
tools for addressing a wide range of real-life challenges. By
combining these technologies with solid computer science
principles, developers can craft solutions that have a meaningful
impact on various industries and domains.

You might also like