On Aug 19, 1:54 am, len <[EMAIL PROTECTED]> wrote: > | lottryid | int(11) | NO | PRI | NULL | > auto_increment | > tupcnt += 1 > rectuple = tupcnt, thekey, a, b, c, d, e, mysum, 0 > listofrec.append(rectuple) > cursor.executemany('''insert into > littlelottery > values (?,?,?,?,?,?,?,?,?)''', listofrec) > > i get the following error on insert; > raise errorclass, errorvalue > TypeError: not all arguments converted during string formatting
{caveat: I'm not a MySQL user] Could this be caused by trying to insert a value for an auto_increment column using the form of insert where you don't specify column names? IOW, your tuple has one more item than it is expecting ... In any case, why have an auto_increment column but then increment it yourself? HTH, John -- http://mail.python.org/mailman/listinfo/python-list