Build a string based on the number of items in your values
, eg:
def place_holder(values):
return '({})'.format(', '.join('?' * len(values)))
values = ['a', 'b', 'c']
ph = place_holder(values)
# (?, ?, ?)
Then something like:
your_cursor.execute('insert into your_table values {}'.format(ph), values)
If it doesn't meet your schema, you'll have issues, but that's another problem...