title: Indexes for where clause and join clause
body: <p>Consider the following:</p>
  
  <ul>
  <li>Table1 with following columns: a, b, m</li>
  <li>Table2 with following columns: a, b, x, y</li>
  </ul>
  
  <p>And this is my query:</p>
  
  <pre><code>select t2.a, t2.b, t1.m
  from table2 t2
  join table1 t1 on t1.a = t2.a 
                and t2.b = t2.b
  where t2.x = 'some value'
    and t2.y = 'some other value'
  </code></pre>
  
  <p>I have to optimize this query.</p>
  
  <p>I have the following non-clustered indices:</p>
  
  <ul>
  <li>index on table1, with column a and b </li>
  <li>index on table2, with column a
  and b </li>
  <li>index on table2, with column x and y</li>
  </ul>
  
  <p>Would I benefit from another index on table2 that would cover all the columns used in this query: a, b, x and y?</p>