MySQLdb: TypeError: not all arguments converted ...

Achim Domma domma at procoders.net
Tue Oct 14 08:42:48 EDT 2003


> cursor.execute("insert into Webpages (Url) values (?)", (url,))
> TypeError: not all arguments converted during string formatting

I have solved it on my own, so just for the records: MySQLdb expects '%s' as
placeholder, not '?' like adodbapi. Is the placeholder specified by the
Python DB Api? Which one is wrong? Or is it an implementation detail?

Achim






More information about the Python-list mailing list