在英文 sql2005中 比较nvarchar 与 varchar的速度

declare @str1 varchar(max);
declare @count int;

set @count = 0;
print 'begin'
while @count < 10000000
begin
set @str1 = @str1 + '*';
set @count = @count +1;
end
print @str1
print 'end'
--time usage:00:01:17

declare @str1 nvarchar(max);
declare @count int;

set @count = 0;
print 'begin'
while @count < 10000000
begin
set @str1 = @str1 + '*';
set @count = @count +1;
end
print @str1
print 'end'
--time usage:00:01:17

--conclusion the same
原文地址:https://www.cnblogs.com/vimmer/p/3216945.html