instead of c.execute(stat, listy[-1]) try sql_list = listy[-1] c.execute(stat, sql_list)
Also what does print stat give you? maybe one of those two would tell us .. Bri! John CORRY wrote: > Hi, > > > > I couldn’t sleep last night with all the code running though my head. > Counting sheep didn’t work as I kept wanting to turn them into a loop! > > > > listy[-1] > > > > Outputs the following:- > > > > ['432', 'TM BLIND', 'RO', 'PF1', 'Plain Finish Range One', '304.8', '', > '45.7', '80', '90', '0', '39', '61', '15.03', '33', '0', '46', '81.3', > '19.38', '42', '0', '60', '101.6', '22.39', '49', '0', '69', '121.9', > '26.39', '58', '0', '81', '142.2', '30.4', '67', '0', '93', '162.6', > '34.41', '75', '0', '105', '182.9', '38.08', '83', '0', '117', '198.1', > '41.42', '90', '0', '127', '223.5', '48.77', '106', '0', '149', '243.8', > '53.12', '117', '0', '163', '274.3', '60.8', '133', '0', '186', '304.8', > '66.14', '145', '0', '202', '0', '0', '0', '0', '0', '0', '0', '0', '0', > '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', > '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0\n'] > > > > The full error is > > > > Traceback (most recent call last): > > File "C:\Python24\Lib\site-packages\databasemanager.py", line 30, in ? > > c.execute(stat, listy[-1]) > > TypeError: parameters must be a list of tuples > > > > Thanks, > > > > John. > > !DSPAM:444211df223121389011208! > > > ------------------------------------------------------------------------ > > _______________________________________________ > Tutor maillist - Tutor@python.org > http://mail.python.org/mailman/listinfo/tutor > > > !DSPAM:444211df223121389011208! _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor