2017-10-09 84 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的 –

回答