1. 程式人生 > >python日常小計

python日常小計

亂碼 技術 utf 查詢 顯示 blog -h 解決 .cn

1、查看變量類型: pring type(item)

2、解決list中的中文顯示亂碼

使用decode(‘string_escap‘)將數據庫查詢返回的將帶轉義的字節碼字符串轉換為成utf-8中文

技術分享

python日常小計