title: check duplicate rows on condition in datatable using linq
body: <p>I have a <code>datatable</code>. it has 5 columns say (Type, A1, A2, B1, B2)
  If Type is A, I want to make sure no 2 rows will have same data in A1 and A2 columns and
  for Type B, no 2 rows will have same data in B1 and B2 columns
  e.g.</p>
  
  <p><code>
      Type | A1  | A2 | B1 | B2 |
      --------------------------
  1   A    | 123 | XY |    |    | 
  2   A    | 123 | XY |    |    |
  3   B    |     |    | TT | LL |
  4   A    | 456 | YZ |    |    |
  5   B    |     |    | TT | LL | 
  6   A    | 123 | YZ |    |    |
  7   B    |     |    | TT | LL |
  8   A    | 456 | YZ |    |    |</code></p>
  
  <p>In this case I want to flag an error on rows 1,2,4,8
  and another error on rows 3,5,7.</p>
  
  <p>Row 6 is OK.</p>
  
  <p>To start with I have done Group by on Key= Type as:</p>
  
  <pre><code>var groups = dt.AsEnumerable().GroupBy(r =&gt; r["Type"]).ToList();
  </code></pre>
  
  <p>I am not sure if I further use for-each on each group or is there a better way in linq.
  Please guide.
  Thanks.</p>