title: SQL WHERE clause with binary
body: <p>I have a SQL Server database table with a <code>varbinary(max)</code> column (i.e. <code>Data VarBinary(max)</code> in a <code>create table</code> command).</p>
  
  <p>Is it possible to do a <code>where</code> clause with some kind of pattern matching within the binary data?</p>
  
  <p>For example, using the C# .NET <code>SqlCommand</code> object, I found that I can do a query like <code>select * from TableName where Data = 0x4638763849838709 go</code>, where the value is the full data column value.  But I want to be able to pattern match just parts of the data, like <code>select * from TableName where Data = 0x%3876% go</code>.</p>
  
  <p>Thanks.</p>