sql server - Calculating MD5 HashBytes for Nvarchar(max) column is possible in SQL? -


i have table column data type nvarchar(max), column have data more 8000 characters.

mytext navarchar(max) 

i want calculate hash value of column, using following code in ms sql 2008/r2

select hashbytes('md5',column_name) 

but getting error as,

string or binary data truncated. 

is possible calculate hash value in nvarchar(max) field in sql query.

or there other ways it.

thanks in advance.

allowed input values limited 8000 bytes mentioned.

try:

select master.sys.fn_repl_hash_binary(cast(column_name varbinary(max)))

for operation have disable fips validated cryptographic algorithms: http://blog.aggregatedintelligence.com/2007/10/fips-validated-cryptographic-algorithms.html


Comments

Popular posts from this blog

mysql - FireDac error 314 - but DLLs are in program directory -

git - How to list all releases of public repository with GitHub API V3 -

c++ - Getting C2512 "no default constructor" for `ClassA` error on the first parentheses of constructor for `ClassB`? -