Beruflich Dokumente
Kultur Dokumente
LITERATURE: This project is a useful platform for students to enquire about the
various possibilities of courses they can take up after completing their intermediate with a
specific stream.
NAMING SPECIFICATIONS:
HOST: localhost
USER: root
PASSWORD: 123
DBMS: Mysql
COURSE_DETAILS table:
mysql> CREATE TABLE IF NOT EXISTS COURSE_DETAILS (C_ID INT(2) PRIMARY KEY, STREAM
VARCHAR(20), C_NAME VARCHAR(50));
Python Code:
import os
import platform
import mysql.connector
import pandas as pd
mycursor=mydb.cursor()
def course_Insert():
L=[]
L.append(c_id)
L.append(stream)
course=(L)
mycursor.execute(sql,course)
mydb.commit()
def cView():
print("1. C_id")
print("2. Stream")
print("3. All")
if ch==1:
s=int(input("c_id : "))
c=(s,)
mycursor.execute(sql,c)
elif ch==2:
n=(s,)
mycursor.execute(sql,n)
elif ch==3:
mycursor.execute(sql)
res=mycursor.fetchall()
def removecourse():
ci=(cid,)
mycursor.execute(sql,ci)
mycursor.execute(sql,ci)
mydb.commit()
userInput = int(input("Please Select An Above Option: ")) #Will Take Input From User
except ValueError:
if(userInput == 1):
courseInsert()
elif (userInput==2):
cView()
elif (userInput==3):
removecourse()
def runAgain():
while(runAgn.lower() == 'y'):
if(platform.system() == "Windows"):
print(os.system('cls'))
else:
print(os.system('clear'))
MenuSet()
runAgain()