title: Deleting orphans from a table
body: <p>I am trying to clean up a table where there are quite a few orphaned items.</p>
  
  <p>I am approaching this by checking to see if there is a relationship to another table by looking for null values.</p>
  
  <pre><code>   DELETE FROM table1 
  LEFT JOIN table2 ON table1.ID = table2.ID
      WHERE table2.ID IS NULL
  </code></pre>
  
  <p>I get an error that the left outer join is not valid.</p>
  
  <p>I am looking for suggestions on other ways that I can delete these orphans from this broken relationship</p>