May-29-2024, 12:33 PM
import mysql.connector mydb = mysql.connector.connect( host="localhost", user="EMG", password="JAMESPaige@63" ) print("Connected to MySQL database:", mydb.database)been trying to run this script to connect to a MySQL Database I am trying to set up with python, it has flagged an issue with no attribute with 'connect' on line 3 which I cant get as I've all the right libraries installed. Coming at this like a beginner as I haven't used Python in 5 years