Computer project
Computer project
BANK MANAGEMENT
SUBMITTED BY
S.Dinesh Kumar
XII–A
First I would like to thank the LORD ALMIGHTY for all the blessings he has
endowed upon me. With profound sense of indebtedness, I thank my parents for their
immense love and support to do this project.
I extend my deep sense of gratitude and heartful thanks to our senior principal
Mr P.Rajasekaran, M.sc., B.Ed., M.Phil., for his inspiring guidance and valuable
suggestions which not only put me on the correct track but enabled me to analyse
the problems from different angles and to complete the project within the stipulated
time.
At last but not the least I express my heartfelt thanks to my family members and
all my friends who had helped me in each and every step I took to complete my
project successfully.
S.Dinesh Kumar
CONTENTS
1 Coding 7
2 Output 11
3 Bibliography 14
KSHATRIYA VIDHYA SALA ENGLISH MEDIUM SCHOOL
This is to certify that S.Dinesh Kumar of Class XII – A has prepared his
report on the project entitled “BANK MANAGEMENT”. This report is the result of
his efforts and endeavours. The report is found worthy of acceptance as Final project
for the subject Computer Science of Class XII – A. He had prepared his report under
my guidance.
CERTIFICATE
is a record of original project work done by me during the year of 2024-2025 under
SCHOOL,VIRUDHUNAGAR.
def OpenAcc():
n=input("Enter the name: ")
ac=input("Enter the Account Number: ")
db=input("Enter Date of Birth: ")
add=input("Enter Address: ")
cn=input("Enter Contact Number: ")
ob=int(input("Enter The Opening Balance: "))
data1=(n,ac,db,add,cn,ob)
data2=(n,ac,ob)
sql1=('Insert into account values (%s,%s,%s,%s,%s,%s)')
sql2=('Insert into amount values(%s,%s,%s)')
x=mydb.cursor()
x.execute(sql1,data1)
x.execute(sql2,data2)
mydb.commit()
print("Data entered successfully")
main()
def DepoAmo():
amount=int(input("Enter amount to be deposited : "))
ac=input("Enter account no: ")
a='select balance from amount where AccNo=%s'
data=(ac,)
x=mydb.cursor()
x.execute(a,data)
result=x.fetchone()
t=result[0]+amount
sql=('update amount set balance=%s where AccNo=%s')
d=(t,ac)
x.execute(sql,d)
mydb.commit()
main()
def withdrawAmount():
amount=int(input("Enter amount to withdraw : "))
ac=input("Enter Account No:")
a='select balance from amount where Accno=%s'
data=(ac,)
x=mydb.cursor()
x.execute(a,data)
result=x.fetchone()
t=result[0]-amount
sql=('update amount set balance=%s where AccNo=%s')
d=(t,ac)
x.execute(sql,d)
mydb.commit()
main()
def BalEnq():
ac=input("Enter account no:")
a='select * from amount where AccNo = %s'
data=(ac,)
x=mydb.cursor()
x.execute(a,data)
result=x.fetchone()
print("Balance for account:",ac,"is",result[-1])
main()
def Disdetails():
ac=input("Enter the account no:")
a='select * from account where AccNo=%s'
data=(ac,)
x=mydb.cursor()
x.execute(a,data)
result=x.fetchall()
for i in result:
print(i)
main()
def CloseAcc():
ac=input("Enter account number:")
sql1='delete from account where AccNo=%s'
sql2='delete from amount where AccNo=%s'
data=(ac,)
x=mydb.cursor()
x.execute(sql1,data)
x.execute(sql2,data)
mydb.commit()
main()
def main():
print('''
1.OPEN NEW ACCOUNT
2.DEPOSIT AMOUNT
3.WITHDRAW AMOUNT
4.BALANCE ENQUIRY
5.DISPLAY CUSTOMER DETAILS
6.CLOSE AN ACCOUNT''')
choice=input("Enter the task you want to perform:")
if (choice == '1'):
OpenAcc()
elif (choice == '2'):
DepoAmo()
elif (choice == '3'):
withdrawAmount()
elif (choice == '4'):
BalEnq()
elif (choice == '5'):
Disdetails()
elif (choice == '6'):
CloseAcc()
else:
print("Invalid Choice")
main()
OUTPUT:
SQL TABLE:
BIBILIOGRAPHY