pymysql.err.InternalError: (1054, "Unknown column 'user' in 'where clause'")

pymysql.err.InternalError: (1054, "Unknown column 'user' in 'where clause'") problems and solutions

Code issues

sql = "select * from user where name =% s"% a 
the% s it quotes
name='nhy'
sql="select * from user where name='%s'"%name

Guess you like

Origin www.cnblogs.com/jingw/p/11222890.html