0% found this document useful (0 votes)
11 views26 pages

School Management System

The document is a project report on a School Management System created by Samarpreet Singh for the academic year 2022-2023. It includes sections such as a certificate of completion, acknowledgments, a synopsis of the project, hardware and software requirements, source code, output, and bibliography. The project utilizes Python and SQL for managing student data, allowing operations like entering, viewing, modifying, and deleting student records.

Uploaded by

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

School Management System

The document is a project report on a School Management System created by Samarpreet Singh for the academic year 2022-2023. It includes sections such as a certificate of completion, acknowledgments, a synopsis of the project, hardware and software requirements, source code, output, and bibliography. The project utilizes Python and SQL for managing student data, allowing operations like entering, viewing, modifying, and deleting student records.

Uploaded by

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

SCHOOL NAME

CRPF PUBLIC SCHOOL ROHINI

ACADEMIC YEAR: 2022-2023

PROJECT REPORT ON

SCHOOL MANAGEMENT
SYSTEM

ROLL NO : _________________

NAME : Samarpreet Singh

CLASS : XII

SUBJECT : COMPUTER SCIENCE

SUB CODE : 083

1
PROJECT GUIDE : Ms. Simmi Gupta

TABLE OF CONTENTS

SER DESCRIPTION PAGE NO

1 CERTIFICATE 3

2 ACKNOWLEDGEMENT 4

3 SYNOPSIS OF THE PROJECT 5

4 HARDWARE AND SOFTWARE REQUIREMENTS 6

5 SOURCE CODE 7-14

6 OUTPUT 15-25

7 BIBLIOGRAPHY 26

2
CERTIFICATE

This is to certify that SAMARPREET SINGH Roll No: ______________ has

successfully completed the project Work entitled SCHOOL MANAGEMENT

SYSTEM in the subject Computer Science (083) laid down in the regulations of

CBSE for the purpose of Practical Examination in Class XII to be held in

CRPF Public School, Rohini.

(Ms. Simmi Gupta)


HOD – Computer Deptt.

Examiner:

Name: _________________

Signature:

3
ACKNOWLEDGEMENT

Apart from the efforts of me, the success of any project depends largely on the
encouragement and guidelines of many others. I take this opportunity to express my
gratitude to the people who have been instrumental in the successful completion of
this project.

I express deep sense of gratitude to almighty God for giving me strength for the
successful completion of the project.

I express my heartfelt gratitude to my parents for constant encouragement while


carrying out this project.

I gratefully acknowledge the contribution of the individuals who contributed in


bringing this project up tothis level, who continues to look after me despite my flaws,

The guidance and support received from all the members who contributed and who
are contributing to this project, was vital for the success of the project. I am grateful
for their constant support and help.

Name : SAMARPREET SINGH

Roll No _________________________________

4
PROJECT ON SCHOOL MANAGEMENT SYSTEM

SYNOPSIS

This program is a program based on the concept of file handling in


python and SQL. This is a database type program for SCHOOL
MANAGEMENT in which the details of the various STUDENTS can be
easily saved, viewed, modified etc.

This program supports following operations on the flights-

∙ Entering Information
∙ Viewing Saved Information
∙ Searching of information
∙ Modification of information
∙ Deletion of information

5
HARDWARE AND SOFTWARE
REQUIREMENTS

I.OPERATING SYSTEM : WINDOWS 7 AND ABOVE

II. PROCESSOR : PENTIUM(ANY) OR AMD

ATHALON(3800+- 4200+ DUALCORE)

III. MOTHERBOARD : 1.845 OR 915,995 FOR PENTIUM 0R MSI

K9MM-V VIAK8M800+8237R PLUS

CHIPSET FOR AMD ATHALON

IV. RAM : 512MB+

V. Hard disk : SATA 40 GB OR ABOVE

VI. CD/DVD r/w multi drive combo: (If back up required)

VII. FLOPPY DRIVE 1.44 MB : (If Backup required)

VIII. MONITOR 14.1 or 15 -17 inch

IX. Key board and mouse

X. Printer : (if print is required – [Hard copy])

SOFTWARE REQUIREMENTS:

I. Windows OS
II. Python

6
SOURCE CODE

∙ CONNECTING MYSQL WITH PYTHON


import mysql.connector as c
mycon = c.connect(host="localhost",user="root",passwd="tiger")
if mycon.is_connected():
print("*************CONNECTION SUCCESSFUL***************")

∙ CREATE FUNCTION
def create():
try:
import mysql.connector as c
mycon =
c.connect(host="localhost",user="root",passwd="tiger",database="samar")
cursor=mycon.cursor()
print("CREATING STUDENT RECORD TABLE........")
query="create table student(ADMN_No int(4) PRIMARY KEY, Student_Name
varchar(60) NOT NULL, Class_Sec varchar(60) NOT NULL, Date_Of_Admn date
NOT NULL, Date_Of_Birth date NOT NULL, Due_Date date NOT NULL, Fine
Varchar(60), Remarks varchar(60))"
cursor.execute(query)
mycon.commit()
print("Created 'STUDENT' table",end="\n")
print()
except:

7
print("PROBLEM IN CREATING",end="\n")

∙ DISPLAY TABLES FUNCTION


def displaytables():
try:
import mysql.connector as c

mycon=c.connect(host="localhost",user="root",passwd="tiger",database="samar")
cursor=mycon.cursor()
cursor.execute("show tables")
for i in cursor:
print(i)
print()
except:
print("ERROR IN SHOWING TABLES")

∙ DESCRIBE TABLES FUNCTION


def describetable():
try:
import mysql.connector as c

mycon=c.connect(host="localhost",user="root",passwd="tiger",database="samar")
cursor=mycon.cursor()
table=input("Enter Table Name: ")
cursor.execute("describe "+table+"")
for i in cursor:
print(i)
print()

8
except:
print("ERROR IN DESCRIBING TABLE")

∙ DISPLAY ALL FUNCTION


def displayall():
try:
import mysql.connector as c

mycon=c.connect(host="localhost",user="root",passwd="tiger",database="samar")
cursor=mycon.cursor()
cursor.execute("select * from student")
data=cursor.fetchall()
print("ADMN NUMBER","STUDENT NAME","CLASS/SEC","DATE OF
ADMISSION", "DUE DATE FOR FINES","STUDENT DATE OF BIRTH","FINE (IF
ANY)","REMARK (IF ANY)", sep="\t")
for i in data:
for j in i:
print(j,end="\t\t")
except:
print("ERROR IN DISPLAYING CONTENTS OF TABLE")

∙ INSERT FUNCTION
def insert():
try:
import mysql.connector as c

mycon=c.connect(host="localhost",user="root",passwd="tiger",database="samar")
cursor=mycon.cursor()
R=int(input("ENTER ADMN NUMBER: "))

9
N=input("ENTER STUDENT NAME: ")
P=input("ENTER CLASS/SEC: ")

A=input("ENTER DATE OF ADMN: ")


B=input("ENTER DATE OF BIRTH: ")
C=input("ENTER DUE DATE FOR FINES: ")
D=input("ENTER FINE (IF ANY): ")
E=input("ENTER REMARKS (IF ANY): ")
query="insert into student values("+str(R)+",'"+str(N)+"','"+str(P)+"','"+str(A)
+"','"+str(B)+"','"+str(C)+"','"+str(D)+"','"+str(E)+"')"
cursor.execute(query)
mycon.commit()
print("STUDENT RECORD SAVED IN TABLE", end="\n")
except:
print("ERROR IN INSERTING RECORDS IN TABLE")

∙ SEARCH FUNCTION
def search():
try:
import mysql.connector as c

mycon=c.connect(host="localhost",user="root",passwd="tiger",database="samar")
cursor=mycon.cursor()
admn=int(input("ENTER ADMN NUMBER OF STUDENT WHOSE RECORD
TO BE SELECTED: "))
query="select * from student where ADMN_No='"+str(admn)+"'"
cursor.execute(query)
data=cursor.fetchall()
if len(data)==0:
print("STUDENT NOT FOUND")

10
else:
print(data)
except:
print("ERROR IN SEARCHING RECORDS FROM TABLE")

∙ DELETE FUNCTION
def delete():
try:
import mysql.connector as c

mycon=c.connect(host="localhost",user="root",passwd="tiger",database="samar")
cursor=mycon.cursor()
admn=input("ENTER ADMN NUMBER OF THE RECORD YOU WANT TO
DELETE: ")
query="select * from student where ADMN_No="+admn+""
cursor.execute(query)

data=cursor.fetchall()
if len(data)==0:
print("STUDENT RECORD NOT FOUND IN TABLE")
else:
qry="delete from student where ADMN_No="+admn+""
cursor.execute(qry)
mycon.commit()

print("STUDENT RECORD HAS BEEN DELETED FROM TABLE")


except:
print("ERROR IN DELETING RECORDS FROM TABLE")

11
∙ UPDATE FUNCTION
def update():
try:
import mysql.connector as c

mycon=c.connect(host="localhost",user="root",passwd="tiger",database="samar")
cursor=mycon.cursor()
admn=input("ENTER ADMN NUMBER OF STUDENT WHOSE RECORD IS
TO BE UPDATED: ")
qry="select * from student where ADMN_No="+admn+ " "
cursor.execute(qry)
data=cursor.fetchall()
if len(data)==0:
print("STUDENT NOT FOUND")
else:
# R=input("ENTER UPDATED ADMN NUMBER: ")
N=input("ENTER UPDATED STUDENT NAME: ")
P=input("ENTER UPDATED CLASS/SEC: ")
A=input("ENTER UPDATED DATE OF ADMN: ")
B=input("ENTER UPDATED DATE OF BIRTH: ")
C=input("ENTER UPDATED DUE DATE: ")
D=input("ENTER UPDATED FINE(IF ANY): ")
qry="update student set Student_Name='"+N+"', Class_Sec='"+P+"',
Date_Of_Admn='"+A+"', Date_Of_Birth='"+B+"', Due_Date='"+C+"',Fine='"+D+"'
where ADMN_NO="+admn+" "
cursor.execute(qry)
mycon.commit()
print("STUDENT RECORD UPDATED")
except:
print("SORRY SOME ERROR OCCURRED")

12
∙ MENU FOR SCHOOL MANAGEMENT SYSTEM SOFTWARE
#MENU FOR SCHOOL MANAGEMENT SYSTEM SOFTWARE
print("*************************************************")
print(" WELCOME TO MY SCHOOL MANAGEMENT SYSTEM")
print("*************************************************")
print()
while True:
print()
print()
print("CHOICE 1 : TO CREATE TABLE (ONLY ONE TIME)")
# print("CHOICE 2 : TO DISPLAY TABLES OF DATABASE")
print("CHOICE 2 : TO SHOW FIELDS OF TABLE")
print("CHOICE 3 : TO DISPLAY ALL DATA OF THE TABLE")
print("CHOICE 4 : TO ADD NEW STUDENT")
print("CHOICE 5 : TO SEARCH A STUDENT'S RECORD")
print("CHOICE 6 : TO CHANGE THE RECORD OF A STUDENT")
print("CHOICE 7 : TO DELETE RECORD OF A STUDENT")
print("CHOICE 8 : EXIT")
print()
ch=int(input("ENTER YOUR CHOICE:"))
#Creating table for the first time
if ch==1:
create()
#Displaying tables of database
# elif ch==2:
# displaytables()
#Displaying Tables fields
elif ch==2:
describetable()
#Displaying all records of table

13
elif ch==3:
displayall()
#inserting new record into table
elif ch==4:
insert()
#searching student details
elif ch==5:
search()
#To update student record
elif ch==6:
update()
# Delete student record from table
elif ch==7:
delete()
#Exit from program
elif ch==8:
exit()
# If the user enters invalid choice
else:
print('Invalid choice')

mycon.close()

×-×-×-×-×-×-×-×-×-×-×-×-×-×-×-×-×-×-×-×

14
OUTPUT

15
16
17
18
19
20
21
22
23
24
25
BIBLIOGRAPHY

In order to work on this project titled –SCHOOL MANAGEMENT


SYSTEM, the following books and literature are referred by me during
the various phases of development of the project:

1) CLASS 12-COMPUTER SCIENCE NCERT TEXTBOOK

2) CLASS 12-COMPUTER SCIENCE TEXTBOOK BY PREETI ARORA

3) GOOGLE.COM

Other than the above-mentioned books, the suggestions and supervision


of my teacher and my classmates also helped me to develop this
software project.

26

You might also like