python solve SQLAlchemy + MySQL database operations Times Warning Warning: (1366, "Incorrect string value: '\\ xD6 \\ xD0 \\ xB9 \\ xFA \\ xB1 \\ xEA ...' for column 'VARIABLE_VALUE' at row 478 ") result = self._query (query)

solution

1. Install mysql-connector-python drive 
  PIP the install mysql-connector-python 
2. Modify Code 
engine = create_engine ( "mysql + pymysql : // root: password @ localhost / my_db") 
to: 
Engine = create_engine ( "+ MySQL mysqlconnector: // root: password @ localhost / my_db ")

 

Detailed documentation may refer to: https://www.jianshu.com/p/e09eb9cc2830

Guess you like

Origin www.cnblogs.com/JentZhang/p/11576865.html