我想用python 2.6.6來使用mysql 5.1,並且出現以下錯誤。 代碼:錯誤1064在python中使用mysql
query = "INSERT INTO present_list SET from='a', to='b'"
print query
cur.execute(query)
錯誤:
Error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'from='a', to='b'' at line 1
有人可以明白什麼是錯的?
Thx,它現在工作! – billx
@ user1865939您不可錯過 –