Skip to content Skip to sidebar Skip to footer

Python Sqlite3 Placeholder

is there a way to set the placeholder for queries in sqlite3 ? I have some functions that work with a database and it would be more satisfying if they could work both with mysql an

Solution 1:

The underlying library doesn't support %s, so it would need to be replaced manually. It might be easier to check the paramstyle attribute and replace all instances of a different placeholder in the query with an appropriate value instead.


Post a Comment for "Python Sqlite3 Placeholder"