In case someone would like to know if HASHBYTES is deterministic: it is!To prove that my statement is correct, try this on the AdventureWorksDW database:ALTER TABLE dbo.dimemployeeADD hashval AS HASHBYTES('SHA1', LastName + '|' + FirstName) PERSISTEDSELECT COLUMNPROPERTY(OBJECT_ID('dbo.dimemployee'), 'hashval', 'IsDeterministic')You'll see that the SELECT statement returns 1. (Also, the ALTER TABLE statement would have failed if the column definition would be non-deterministic.)
↧