I am trying to push a large csv of data into a mysql database and keep getting errors so I have simplified the insert to the following. I have seen a number of similar questions on here, but I haven't been able to get those to work for me. What am I missing? It should also note that it prints fine when I try that.
import MySQLdb as mdb
con = mdb.connect(host='', port=3306, user='', passwd='', db='')
cursor = con.cursor()
cursor.executemany("INSERT INTO schema.table (Account_Number, Sales_Total) "
"VALUES(%s, %s)", ('Account 1', 2))
error:
TypeError: not enough arguments for format string