title: How can I use Proc SQL to find all the records that only exist in one table but not the other?
body: <p>I'm trying to do this in Enterprise Guide, with a task, otherwise I would just use a data step.</p>
  
  <p>In a data step, this would be:</p>
  
  <pre><code>data names;
   input name $;
   datalines;
    John
    Mary
    Sally
    Fred
    Paul
   ;
  run;
  
  data check;
   input name $;
   datalines;
    Mary
    Fred
   ;
  
  Proc sort data=names; by name; run;
  Proc sort data=check; by name; run;
  
  Data work.not_in_check;
   merge names(in=n) check(in=c);
   by name;
   if n and not c;
  run;
  </code></pre>