hashbytes, :
, hashbytes SQL .
Hashbytes varbinary. , , . SQL hashbytes('SHA2_512,'stuff'), 's', 't', 'f'. '\ 0'. sqlcommand, '\ 0' , SQL . , Encoding , .
, addwithvalue .
But you know that exectescalar returns an object. If the query returns null strings, the object will be NULL, and you cannot overlay or convert the NULL object to anything. Therefore, in the if statement we say: "if the returning object is == null, then you are not authorized. Else ..."
source
share