Posted By: harumscarum | Apr 2nd @ 8:47 AM
page 1 of 1
Comments: 2 | Views: 613
harumscarum
harumscarum
out of memory
Why would each of these return a different result?


1:
SELECT CHECKSUM('FUZZYWUZZY')  from foobear 



2:
Declare @foo nvarchar(MAX)
set @foo = 'FUZZYWUZZY'
select checksum(@foo) from foobear


W3bbo
W3bbo
The Master of Baiters
String literals in SQL aren't nvarchar, they're char.

Prefix strings with N'' to convert them into nchar; but I don't believe you can have a varchar literal.
Because Fuzzy Wuzzy wasn't fuzzy, was he?
page 1 of 1
Comments: 2 | Views: 613
Microsoft Communities