I have a table with different columns (pageNum, value1, value2, value3).
I want to do something like that in python3.3 and sqlite3:
selection = (100, 200, 300)
cursor.execute(""" SELECT value1, value3
FROM myTable
WHERE value2>? and pageNum IN ?
""", (10, selection))
But seems like it is complaining:
sqlite3.OperationalError: near "?": syntax error
Note that the question is about how to use the IN
clause that way, not about how to do the query, which of course in that case it could be done in a different way.