title: SQL: Performance comparison for exclusion (Join vs Not in)
body: <p>I am curious on the most efficient way to query exclusion on sql. E.g. There are 2 tables (tableA and tableB) which can be joined on 1 column (col1). I want to display the data of tableA for all the rows which col1 does not exist in tableB. </p>
  
  <p>(So, in other words, tableB contains a subset of col1 of tableA. And I want to display tableA without the data that exists in tableB)</p>
  
  <p>Let's say tableB has 100 rows while tableA is gigantic (more than 1M rows). I know 'Not in (not exists)' can be used but perhaps there are more efficient ways (less comp. time) to do it.? I don't maybe with outer joins?</p>
  
  <p>Code snippets and comments are much appreciated.</p>