I am trying to use HASHBYTES with MD5 algo. but getting different results depending upon how the data is passed i.e.,
if passed using a variable
SELECT HASHBYTES('MD5', @Var)
shows the result 0xBEC062C01D70F0D2FC15F2E43EE3A66Bif passed direclty
SELECT HASHBYTES('MD5', 'asd123')
shows the result 0xBFD59291E825B5F2BBF1EB76569F8FE7
I inserted the data using INSERT but when I try to retrieve using my STORED PROCEDURE, no records are displayed.
Is there something I'm missing?