title: Sql query insert hex string into varbinary(max) gives wrong results
body: <p>With the following sql query I will get the wrong input into my database (Microsoft SQL Server 2008) table:</p>
  
  <pre><code>INSERT INTO [dbo].[test]([ExampleWorking],[ExampleWrong])VALUES(0xFF, 0xFFFF)
  </code></pre>
  
  <p>whereas ExampleWorking &amp; ExampleWrong are both VARBINARY(max)</p>
  
  <p>The result in the database is:</p>
  
  <p>ExampleWorking = 0xFF
  ExampleWrong = 0x3F (I was expecting 0xFFFF here)</p>
  
  <p>What do I miss here?
  I'm new to SQL and it's data types though.</p>