I have to update simple table using below expression:
cur.executemany('UPDATE earths SET population=?, density=?, tilt=?, "land area"=?, dobe=?, livity=? WHERE sid=' + str(dc['sid']) + ' AND nr=' + str(dc['nr']), v)
Printing the content it gets:
('UPDATE earths SET population=?, density=?, tilt=?, "land area"=?, dobe=?, livity=? WHERE sid=15821 AND nr=8',
['1360425627', '2.79', '17.33', '486857065.504', '17.88371', '0.08'])
The error I get is:
ProgrammingError: Incorrect number of bindings supplied. The current statement uses 6, and there are 10 supplied.
I don't know how the program sees 10 values from 6 element list. Any ideas? The table is ok - inserting data one by one gives ok values. It looks
UPDATE earths SET population=1360425627, density=2.79, tilt=17.33, "land area"=486857065.504, dobe=17.88371, livity=0.08 WHERE sid=15821 AND nr=8