查看: 839|回复: 3
|
救命! 不能retrieve中文字from mysql DB!
[复制链接]
|
|
小弟已经在connection string 加了CHARSET=utf8 , 但依然不能将中文字insert into mysql DB
显示在DB的尽是 ??????
过后我manually keyin 中文字在mysql DB, 但显示出来的record也一样是????
我已经在每一页加了CodePage="65001"
-------------------------------------------------------------------
<%@ Page Language="VB" CodePage="65001" AutoEventWireup="false" CodeFile="result_detail.aspx.vb" Inherits="frontend_result_detail" %>
同时也在page_load放了
Session.CodePage = 65001
Response.Charset = "utf-8"
-------------------------------------------------------------------
Dim ConnStr As String = "DRIVER={MySQL ODBC 3.51 Driver};" & _
"SERVER=localhost;" & _
"DATABASE=db_customer;" & _
"UID=user;" & _
"PASSWORD=password;" & _
"OPTION=3;" & _
"CHARSET=utf8;"
请可以懂得解决这个问题的朋友帮助我一下
|
|
|
|
|
|
|
|
发表于 6-8-2007 11:14 AM
|
显示全部楼层
|
|
|
|
|
|
|

楼主 |
发表于 6-8-2007 06:42 PM
|
显示全部楼层
谢谢你的建议。。 但我已经作了这个更动但还是不行
请问谁有相关的资料可以给我做以下的东西吗?
storing the chinese character in hex before insertion and decode it while displaying after retrieving from the database. |
|
|
|
|
|
|
|
发表于 7-8-2007 10:41 AM
|
显示全部楼层
原帖由 counterking 于 6-8-2007 06:42 PM 发表 
谢谢你的建议。。 但我已经作了这个更动但还是不行
请问谁有相关的资料可以给我做以下的东西吗?
storing the chinese character in hex before insertion and decode it while displaying after retrievin ...
以下是我在DB的data,设定了collation
http://bayimg.com/GAfLKAAbF
那些就是UNICODE.你的游缆器有把character encoding 设订去 UNICODE(UTF8)吗?如果是手动去输入中文字,应该没问题
去参靠一下:
http://www.w3.org/International/O-HTTP-charset
http://lists.evolt.org/archive/Week-of-Mon-20051017/176877.html
http://forums.asp.net/t/1108657.aspx |
|
|
|
|
|
|
| |
本周最热论坛帖子
|