SQL 插入多语言字符
我正在尝试在 MS SQL 数据库中为语言创建一个表。
我想在数据库中存储语言的英文名称和语言的本地名称。 即
语言,语言(本地)
英语, 英语
德语、德语
意大利语,意大利语
日语、日本语
...
...
我想导入 279 种语言,但导入时显示“??????”对于日语、俄语和阿拉伯语等
数据库排序规则为 Latin1_General_CI_AS。
我还想获得有关多语言网站的建议;如果我有一个产品描述数据库,并且我想进行多种语言的翻译,我应该使用单独的数据库还是可以在一个数据库中进行翻译? (我不想重复数据!)。还有什么可以确保用户能够用不同的语言编写评论(网络上的字符编码?)并且可以存储在数据库中。
感谢建议,我已成功导入数据,但是我无法正确选择和查看,因此无法验证导入是否成功;我在选择时得到以下结果:
I am trying to create a table in my MS SQL database for Languages.
I want to store an English name of Language and a local name of language in the database.
i.e.
Language, Language(local)
English, English
German, Deutsch
Italian, Italiano
Japanese, 日本語
...
...
I have 279 languages that I want to import, but when I import it shows '?????' for some like japanese, Russian and arabic etc
The database Collation is Latin1_General_CI_AS.
I would also like advise on multilingual websites; if i have a database of product descriptions and I want to have translation in multiple languages, should I go for separate databases or Can I have translation in one databse? (I prefer not to duplicate data!). Anything else to make sure users are able to write comments in different languages (char encoding on web?) and can be stored in database.
Thanks to an advise I have managed to import data but, I cannot select and view correctly and therefore cannot verify if import was successful; I am getting following results on select:
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我认为你需要的是 nvarchar
http://msdn.microsoft.com/de- de/library/ms186939.aspx
编辑:
查询
i think what you need is nvarchar
http://msdn.microsoft.com/de-de/library/ms186939.aspx
EDIT:
quering
ASP.NET 具有相当可靠的基础结构来处理本地化。比推出自己的多语言支持容易得多。
http://quickstarts.asp.net/QuickStartv20/aspnet/doc/localization /本地化.aspx
ASP.NET has a pretty solid infrastructure for handling localization. Much easier than rolling your own multi-language support.
http://quickstarts.asp.net/QuickStartv20/aspnet/doc/localization/localization.aspx