title: How do you suppress or hide duplicate values in SQL?
body: <p>I've been looking around for a bit and have not been able to find out how to do this yet (though have found alot about analyzing it's performance?!)</p>
  
  <p>I want to perform a select which returns a few columns of data, and then also a nested table of related rows from another table (actually the same table joined on itself but I 'think' this is irelevant).</p>
  
  <p>So the data is something like this:</p>
  
  <pre><code>id  name   registered
  1   Dan      N
  2   Bill     N
  3   Bob      N
  4   Dan      N
  5   Bill     Y
  6   Dan      Y
  </code></pre>
  
  <p>The idea is perform a select which finds all the unregistered people who could be related to a registered account.</p>
  
  <p>So the result would look like</p>
  
  <pre><code>registered.id   name   notreg.id   name
    5             Bill     2          Bill
    6             Dan      1          Dan
                           4          Dan
  </code></pre>
  
  <p>I alright with SQL can handle all the selection criteria etc, and have a query that returns a normal inner join that finds this, but want to know if it's possible to get a result set kind of like this, so no repeated values on the left side??</p>