MySQLDB: Python: Inserting date, integer, float and other variables into MySQL

The best way to insert values into a database using MySQLDB would be to simply use ‘%s’. This placeholder does all the work on conversion into other data types. You dont need to worry about converting any values into their respective datatypes in mysql.

2 Replies to “MySQLDB: Python: Inserting date, integer, float and other variables into MySQL”

Leave a Reply

Your email address will not be published.