sql server 表连接报错

报错信息:

Cannot resolve the collation conflict between "Chinese_PRC_CI_AI_WS" and "Chinese_PRC_CI_AS" in the equal to operation.

解决方法:

1.强制指定用一种字符编码来排序,在where条件语句中添加排序规则,如:COLLATE Chinese_PRC_CI_AI_WS

select id,cn
from tb_A
where cn COLLATE Chinese_PRC_CI_AI_WS in(select cn from tb_B);

猜你喜欢

转载自blog.csdn.net/u013347671/article/details/88688448
今日推荐