title: JOIN or Correlated subquery with exists clause, which one is better
body: <pre><code>select * 
  from ContactInformation c 
  where exists (select * from Department d where d.Id = c.DepartmentId )
  
  select * 
  from ContactInformation c 
  inner join Department d on c.DepartmentId = d.Id  
  </code></pre>
  
  <p>Both the queries give out the same output, which is good in performance wise  join or correlated sub query with exists clause, which one is better.</p>
  
  <p>Edit :-is there alternet way for joins , so as to increase performance:-
  In the above 2 queries i want info from dept as well as contactinformation tables</p>