你好,我有一个问题:
我的意见:
import mysql.connector
import mysql.connector
mydb = mysql.connector.connect(
host = 'localhost',
user = 'root',
passwd = 'ananthjeahinowiamshowingmypasswordwitchisnotmypassword'
)
print(mydb)
这是输出:
mysql.connector.errors.NotSupportedError: Authentication plugin
'caching_sha2_password' is not supported
现在可以了谢谢
我使用了一个mysql插件,所以它会工作
谢谢
安装python-MySQL驱动程序
official document
Similiar stack question
只需确保根据您的操作系统、MySQL版本和Python版本安装正确的连接器 pip安装mysql连接器python
相关问题 更多 >
编程相关推荐