15 12
发新话题
打印

[提问] 用asp.net+MS SQL Server数据库插入中文出现乱码

用asp.net+MS SQL Server数据库插入中文出现乱码

我的web.config已经改成
<globalization requestEncoding=”gb2312″ responseEncoding=”gb2312″ culture=”zh-CN” fileEncoding=”gb2312″ />
了,还是不行,
甚至,我直接在godaddy网站上提供的web Admin管理页面的sql server查询分析器里用sql插入中文就不行,
如:
insert into news (name,topic) values ('我','乱码!!!');
也是乱码阿。

大家有没有遇到过的?
怎么解决阿??

TOP

没有人可以帮忙解决么???

TOP

在web.config加入:
复制内容到剪贴板
代码:
<system.web>
<globalization requestEncoding="gb2312" responseHeaderEncoding="gb2312" />
</system.web>
[ 本帖最后由 zihaow 于 2007-11-8 11:56 PM 编辑 ]
我的IT技术博客 http://www.wx35.cn

TOP

大哥,
请先看清俺的问题。

TOP

没戏了,
建议大家不要用godaddy的sql server数据库做中文网站了,
我给他们email,回复说他们的sql server现在不支持中文!!!!

TOP

汗!不是吧,楼上的,你问过?
我认为可以用utf-8编码实现吧。

TOP

MSSQL可以用中文,这个出问题的不对,ACCESS出问题的多

TOP

楼上,怎么用中文啊?
我直接用sql插入中文都不行。应该不是编码的问题:
(俺用的是Deluxe Plan型主机)

这是他们email的回复:



Discussion Notes
Support Staff Response
Dear Sir/Madam,

Thank you for contacting Online Support.

Unfortunately, we do not currently support the use of non-Western (Latin) character sets in SQL Server databases setup on our shared hosting. I do apologize for any inconvenience this may cause.

Please let us know if there is anything else we can assist you with.

Sincerely,

Jarrod P.
Online Support Technician

TOP

换成GBK咋样

TOP

直接在godaddy网站上提供的web Admin管理页面的sql server查询分析器里用sql插入中文都不行,
如:
insert into news (name,topic) values ('我','乱码!!!');
数据库中也是乱码!!!

TOP

 15 12
发新话题