郞性人生

导航

Python 操作 MySQL数据库提示pymysql.err.InternalError: (1054, "Unknown column 'XXXXXXXXX' in 'where clause'")解决方法

Python 操作 MySQL数据库提示pymysql.err.InternalError: (1054, "Unknown column 'XXXXXXXXX' in 'where clause'")

原因:

这种错误,一般是因为SQL语句中的%s没有加双引号" "或单引号' '引起的; 

解决方法:

在SQL语的%s两边加双引号" "或单引号' ',就可以了;

posted on 2020-10-28 18:33  郞性人生  阅读(3113)  评论(0编辑  收藏  举报