Create Table Student

You might also like

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 1

create table student

import mysql.connector
mydb=mysql.connector.connect(host="localhost",\
user="root",\
passwd="ankit",\
database="KVK")
mycursor=mydb.cursor()
mycursor.execute("create table student(adno int(10), session varchar(10), stname varchar(30), stclass
varchar(10), stsec varchar(5), stroll varchar(3), sub1 varchar(10),sub2 varchar(10),sub3 varchar(10))")
for x in mycursor:
print(x)

You might also like