python pandas数据处理赋值编码错误UnicodeWarning: Unicode equal comparison failed to convert both
发布网友
发布时间:2022-05-09 23:52
我来回答
共1个回答
热心网友
时间:2023-10-14 01:21
for row in csv.reader(open(r'testm.csv','rb'),delimiter=','):
sql=""
cursor = MySqlConn.cursor()
cursor.execute(sql)
dbRet=cursor.fetchone()
if not tuple(row)==dbRet:
#其他操作
在ubuntu下if判断出现异常信息:
UnicodeWarning: Unicode equal comparison failed to convert both arguments to Unicode - interpreting them as being unequal.