惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Stack Overflow Blog
Stack Overflow Blog
PCI Perspectives
PCI Perspectives
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
V2EX - 技术
V2EX - 技术
Google DeepMind News
Google DeepMind News
量子位
博客园_首页
S
SegmentFault 最新的问题
S
Secure Thoughts
F
Full Disclosure
H
Hacker News: Front Page
博客园 - 三生石上(FineUI控件)
U
Unit 42
H
Heimdal Security Blog
N
News and Events Feed by Topic
A
About on SuperTechFans
C
CERT Recently Published Vulnerability Notes
Cyberwarzone
Cyberwarzone
Help Net Security
Help Net Security
The Hacker News
The Hacker News
L
LINUX DO - 最新话题
Application and Cybersecurity Blog
Application and Cybersecurity Blog
罗磊的独立博客
N
News | PayPal Newsroom
Spread Privacy
Spread Privacy
C
Cisco Blogs
C
CXSECURITY Database RSS Feed - CXSecurity.com
云风的 BLOG
云风的 BLOG
A
Arctic Wolf
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
Simon Willison's Weblog
Simon Willison's Weblog
B
Blog
人人都是产品经理
人人都是产品经理
TaoSecurity Blog
TaoSecurity Blog
博客园 - 【当耐特】
C
Cyber Attacks, Cyber Crime and Cyber Security
P
Proofpoint News Feed
Hugging Face - Blog
Hugging Face - Blog
I
InfoQ
D
DataBreaches.Net
大猫的无限游戏
大猫的无限游戏
Apple Machine Learning Research
Apple Machine Learning Research
L
LINUX DO - 热门话题
Google Online Security Blog
Google Online Security Blog
V
Visual Studio Blog
V
Vulnerabilities – Threatpost
Know Your Adversary
Know Your Adversary
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
B
Blog RSS Feed

博客园 - 流云之心

招人啦 - 前端,后台开发专家 为什么不给程序员配好电脑 [翻译] SQL Server中对XML操作 开发常用小工具介绍 设计模式一 - Simple Factory, Factory Method, Abstract Factory以及Builder模式简述 强制休息程序 - EyeGuardian 眼睛守护者 Beta测试版 定时计划任务方案比较以及通过脚本创建计划任务(SchTasks命令) javascript 将页面上的Table导出保存为Excel (无格式) - 流云之心 Excel Programming (C# + VBA) Part III Excel Programming (C# + VBA) Part II Excel programming (C# + VBA) Part 1 Harry Potter - The Half-Blood Prince 转移阵地了,新地址:http://spaces.msn.com/members/PuGong 关于XMLHTTP object的OPEN方法 smart client优势在那里? (草稿) Microsoft Interview Question links 转自http://blogs.msdn.com/chappell/archive/2004/07/20/189364.aspx MSN to expand free e-mail storage to 250MB 用 #inculde file = "../fiel" 报1031错误 用<!--include file = ../ --> 报错误1031
SQL Server的collation问题
流云之心 · 2004-08-20 · via 博客园 - 流云之心

前不久为一个美国客户做了个.net程序,在创建数据库的时候没有注意collation就使用了默认的Server Collation设置:Chinese_PRC_CI_AS。而在安装过程中,我们使用我们这边的一个seed database的备份数据库恢复来把数据库安装到客户的SQL Server上面。结果不久之后客户使用过程中就发现异常。后来仔细查看后才发现原因,就是客户SQL Server的collation和我们数据库的collation设置不一致。客户的SQL Server使用Latin1_General_CI_AS,服务器上的所有默认数据库都是使用这个collation,包括temp, master数据库。只有我们的数据库是Chinese_PRC_CI_AS。由于我们在部分存储过程里面使用了临时表保存数据,而临时表放在temp数据里面,在创建临时表的时候对string类型的字段如果不指定的话就会使用temp数据库的默认collation设置。在我们的开发环境里面测试不会有任何问题,但是程序到客户那里后就出现问题了,应为在SQL Server不同collation的数据是不能进行比较的,当我们运行使用到使用到临时表的功能时就会报错。
当客户报这个错误的时候,刚开始没有想到是这个原因,我们花了不少时间想法设法在开发环境里面重现这个错误,最后安装了一套和客户软件环境一模一样的系统后才发现是这个原因。目前的解决方法是在在创建临时表的时候强行把string等类型的collation设置为Chinese_PRC_CI_AS.  这样临时表的collation的设置就和我们的数据库里面的一致。

建议大家最好在设计阶段就把这些问题考虑进去。