title: SQL Server: Inserting a list of ints into a temporary table
body: <p>I have a list of IDs in a text file like this:</p>
  
  <pre><code>24641985 ,
  24641980 ,
  24641979 ,
  24641978 ,
  24641976 ,
  24641974 ,
  ...
  ...
  24641972 ,
  24641971 ,
  24641970 ,
  24641968 ,
  24641965)
  </code></pre>
  
  <p>There's tens of thousands of them.</p>
  
  <p>Now I need to know which ids are in this list, that do not correspond to an ID in my table.</p>
  
  <p>I guess I should put them into a temporary table, then say something like:</p>
  
  <pre><code>select theId 
    from #tempIdCollection
   where theId not in (select customerId from customers)
  </code></pre>
  
  <p>Problem is I don't know how to get them into the temp table!</p>
  
  <p>Can anyone help? This doesn't have to be efficient. I've just got to run it once. Any solution suggestions welcome!</p>
  
  <p>Thanks in advance!</p>
  
  <p>-Ev</p>