x = self.npprocess_PTE.text()
y = 123
if len(self.npprocess_PTE.text()) == 0:
print("yes")
else:
model = QtGui.QStandardItemModel()
self.npprocessview_LV.setModel(model)
z = model.rowCount()
z = z + 1
a = str(z)+'_Process'
b = "INSERT INTO new_part_info(%s) VALUES(%s) WHERE Part_ID = %s"
c = (z, x, y)
mycursor.execute(b, c)
mydb.commit()
The error i am getting:u have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '1) VALUES('wb') WHERE Part_ID = 123' at line 1