MSSQL 相同的排序规则列显示不同的数据

MSSQL same collation columns show different data

我有两个数据库。 我从第一个数据库获取数据并将其放入第二个数据库。
所以我有相同列的主要问题

(collation - Latin1_General_CI_AS, data type - nvarchar, length - 90) .

但第一个数据库的列显示特定符号,如“ā”、“ī”、“ē”等,第二个数据库的列将其变为 "a"、"i"、"e"。

那么你能告诉我发生这种情况的原因吗?

您需要确保为 Unicode 字符串文字添加 N 前缀。像这样。

查询 1:(旧查询的字符串)

SELECT 'If the alternative 
 hypothesis is as  Ha:µ ≠µ0';

输出:

If the alternative hypothesis is as Ha:µ ?µ0

在上面的查询中缺少

查询 2:(新查询的字符串)

SELECT 'If the alternative 
 hypothesis is as  Ha:' + N'µ ≠µ0';

输出:

If the alternative hypothesis is as Ha:µ ≠µ0