title: Correct way to set collation in temporary table column TSQL
body: <p>I have a temporary table which gets data inserted using bulk insert. However, when I want to update data from temp table to a normal table it gives collation problems. I know how to solve this by using something like: </p>
  
  <pre><code>UPDATE RegularTable
  SET r.Column1 = t.ColumnA
  FROM RegularTable r INNER JOIN #TEMP t ON
  r.Column1 COLLATE DATABASE_DEFAULT = 
  t.ColumnA COLLATE DATABASE_DEFAULT
  </code></pre>
  
  <p>But, is there a way to set the collation in the temporary table immediately so you don't have to use collate in the join? Something like:</p>
  
  <pre><code>CREATE TABLE #TEMP
  Column1 varchar(255) COLLATE database_default,
  Column2 varchar(60) 
  </code></pre>
  
  <p>Is this correct coding and do you have to set the collation once per table or per column?
  And if the collation is set in the table, can you exclude the collate from the join then?</p>