2017-10-09 83 views
0

我使用带有内部数据库(utf8mb4_unicode_ci,utf8mb4,InnoDB)的外部数据库(charset:latin1_swedish_ci,collat​​ion = latin1,MyISAM)。Mysql(在Laravel中)DB排序规则和图表设置

  • customer_name : collation = utf8mb4_unicode_ci
  • customer_email : collation = utf8mb4_unicode_ci

因此,每次从外部数据库获取数据时,都会收到以下异常警告。

在我的情况下,我应该如何修改数据库设置?谢谢。


(3/3)QueryException

SQLSTATE [HY000]:常规错误:错误1366字符串值: '\ xF8peri ......' 在第1行(SQL列 'CUSTOMER_NAME':插入customersidcustomer_namecustomer_email)值(10008,奥尔森Naen Klistpe AS,[email protected]))


外部DB enter image description here

内部DB enter image description here


测试系统:Win10(64位)时,MySQL(v5.7.19,InnoDB的),PHP(V7.1),Laravel(V5.4 )

+0

Dup的https://stackoverflow.com/questions/46648829/mysql-setting-for-correct-character-and-collat​​ion-in-laravel的 –

回答