This video is based on how data is being fetch from sql with python
import mysql.connector
mycon=mysql.connector.connect(host="localhost",user="root",passwd="1234",database="school")
if mycon.is_connected()==False:
print("error in connecting")
else:
print("connecting to the databse")
cursor=mycon.cursor()
cursor.execute("select * from student")
data=cursor.fetchall()
for row in data:
print(row)