if __name__ == '__main__':
    cnx = mysql.connect(user='root')
cur = cnx.cursor()
cur.execute('SELECT FROM_UNIXTIME(%s)', (1268811665,))
print(cur.fetchall())
cur.close()
cnx.close()
In Python, if I have a unix timestamp, how do I insert that into a MySQL datetime field?