title: What kind of datatype should one use to store hashes?
body: <p>I understand that hashes will be different based on different datatypes in SQL Server. One support Unicode another not .... so on (also collation)</p>
  
  <p>I am using char(32) as a datatype but the output is weird. 
  Using this</p>
  
  <pre><code>select HASHBYTES('MD5','MD5Text')
  </code></pre>
  
  <p>gives this ouput:</p>
  
  <pre><code>0xA891DB2DA259280A66FD5F35201CAB6A
  </code></pre>
  
  <p>and when</p>
  
  <pre><code>declare @h char(32)
  select @h=HASHBYTES('MD5','MD5Text')
  select @h,LEN(@h)
  </code></pre>
  
  <p>output:</p>
  
  <p>Ё‘Ы-ўY( fэ_5 «j </p>
  
  <p>So I am new to SQL Server.<br>
  Could anyone, please, tell me what datatype should I use to store hashes ??</p>