Hello Itversity team,
Can you please install needed package to connect mysql db from python.
I needed it to practice some python project.
For example, something like below:
pip install MySQL-python
pip install mysql-connector-python
pip install pymysql
I already checked these post and looks like this issue is not resolved.
I was getting this error while running python script. Could you please check how to connect to mysql db from python , or let me know if there is any alternative way
ImportError: No module named MySQLdb
Thanks to itversity team for providing the platform to learn more !!
I am very new to python. Started learning from itversity.
I am trying to implement part of it in bigdata labs.
import mysql.connector, datetime
from mysql.connector import errorcode
cnx = mysql.connector.connect(user=retail_dba, password=itversity,
cursor = cnx.cursor()
query = (“select * from customers limit 10”)
for i in cursor: