字符编码修改
This commit is contained in:
parent
25ecad6581
commit
04a7e43960
@ -74,8 +74,9 @@ def saveTofile(save_info,save_name):
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
def buildWid():
|
def buildWid(databaseName):
|
||||||
|
|
||||||
|
database_name = databaseName
|
||||||
select_min_idx = 10000
|
select_min_idx = 10000
|
||||||
select_max_idx = select_min_idx + 100
|
select_max_idx = select_min_idx + 100
|
||||||
|
|
||||||
@ -102,7 +103,9 @@ def buildWid():
|
|||||||
idx = player_info[5]
|
idx = player_info[5]
|
||||||
accountid = player_info[6]
|
accountid = player_info[6]
|
||||||
|
|
||||||
new_str = '%s%s%s%s%s'%(country, province, city, sex, nickname)
|
nickname_string=str(nickname,'utf-8')
|
||||||
|
str1 = '%s%s%s%s'%(country, province, city, sex)
|
||||||
|
new_str = str1 + nickname_string
|
||||||
md5_str = translateToMd5(new_str)
|
md5_str = translateToMd5(new_str)
|
||||||
update_sql = "UPDATE %s SET wid = '%s' where accountid = '%s';"%(table_name,md5_str,accountid)
|
update_sql = "UPDATE %s SET wid = '%s' where accountid = '%s';"%(table_name,md5_str,accountid)
|
||||||
saveTofile(update_sql,save_file_name)
|
saveTofile(update_sql,save_file_name)
|
||||||
@ -114,4 +117,4 @@ def buildWid():
|
|||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
buildWid()
|
buildWid('accountdb1')
|
||||||
|
Loading…
x
Reference in New Issue
Block a user