table = 'mytable'
columns_string = '(' + ','.join(list(myDict.keys())) + ')'
values_string = '(' + ','.join(map(str, list(myDict.values()))) + ')'
sql = """INSERT INTO %s %s
     VALUES %s""" % (table, columns_string,
    values_string)
Using a Python dict for a SQL INSERT statement