Python調用MySQLdb插入中文亂碼的問題

#!/usr/bin/python # -*- coding: utf-8 -*- import MySQLdb def main(): fullname = "趙錢孫李" conn = MySQLdb.connect(host='localhost', user='root',passwd='123', db='account', charset='utf8')  # OK
相關文章
相關標籤/搜索