On Fri, Mar 21, 2008 at 12:42 PM, Spencer Parker <[EMAIL PROTECTED]>
wrote:
> This is all that I get when I run it...
>
> Traceback (most recent call last):
> File "./loadcsv.py", line 23, in ?
> co.execute("""
> File "/usr/lib64/python2.4/site-packages/MySQLdb/cursors.py", line 148,
> in execute
> query = query % db.literal(args)
> TypeError: not all arguments converted during string formatting
>
> co.execute("""
> > > INSERT INTO stats VALUES
> > >
> > (%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s);
> > > """,row)
> >
>
You have triple quotes around your SQL. That means that "implied" line
breaks become real. It won't look as nice, but take the line breaks out and
I think it ought to work.
Just my $.02...
--
www.fsrtechnologies.com
_______________________________________________
Tutor maillist - [email protected]
http://mail.python.org/mailman/listinfo/tutor