Scenario: # myvalues (1L,'text') # sql="INSERT INTO %s (%s) VALUES %s"% (db,",".join(myfields),myvalues) This doesn't work, because the Integer-Value (1L) is not converted into a Integer (without 'L'), so the INSERT statement is: INSERT INTO db (id, sometext) VALUES (1L,'text') ^^ :-( What can I do? Ansgar