SQLite Forum

Error in SQLite 'all VALUES must have the same number of terms'
Login
> create_invoices = """ INSERT INTO invoices (invoice_no, date, customer_name, gstin, product, hsn, uom, quantity, rate, amount, supplier) VALUES (?,?),('list') """ 

Ignoring quite a bit of information not relevant to the error shown in your thread title, I say: Your INSERT statement claims that 11 columns are to given values, (by naming them in the first parenthesized list), then provide only a set of 2 values (<code>(?,?)</code>) and set of 1 value (<code>('list')</code>). For that INSERT statement to be semantically valid, the value lists would each need to have 11 members. Because it is not semantically valid, the statement preparation phase rejects that SQL with the error you see.