title: Ms Access 2010 issue with a where clause in C#
body: <p>I have a complex <code>select</code> statement for an Access 2010 database which grabs data from multiple tables using several <code>LEFT JOIN</code> statements. The query works as expected and I get the entire table.</p>
  
  <p>So now I want to add search functionality.
  One way was to add a <code>WHERE</code> clause at the end of the query and reference one of the <code>JOIN</code>ed tables' text field and compare it against some text (<code>WHERE [All Names].Name LIKE "*Mark*"</code>).</p>
  
  <p>Second option I tried was <code>select * from (**complex sql here**) where **condition**</code></p>
  
  <p>Now in both cases, when my condition is something simple like <code>([ID]&lt;15)</code>, it works like a charm, but when I change it to <code>([Employee Name] LIKE "\*Mark\*")</code> or the one in option 1, it produces an empty data table as if the request goes through, there is no error or exception, all the field names are present, but no rows are returned.</p>
  
  <p>However, if I grab the full string of the generated SQL string (either option) using the debugger (or just dump it into a text file), and then with literally no changes put that string directly into a new Access query, it works fine and returns several fields where the name contains "Mark"</p>
  
  <p>Very simply put, a query that works fine within Access, does not work from within C#.</p>
  
  <p>So I am now confused</p>