title: SQL Joins Vs SQL Subqueries (Performance)?
body: <p>I wish to know if I have a <strong>join</strong> query something like this - </p>
  
  <pre><code>Select E.Id,E.Name from Employee E join Dept D on E.DeptId=D.Id
  </code></pre>
  
  <p>and a <strong>subquery</strong> something like this -</p>
  
  <pre><code>Select E.Id,E.Name from Employee Where DeptId in (Select Id from Dept)
  </code></pre>
  
  <p>When I consider <strong>performance</strong> which of the two queries would be faster and <em>why</em> ?</p>
  
  <p>Also is there a time when I should prefer one over the other?</p>
  
  <p>Sorry if this is too trivial and asked before but I am confused about it. Also, it would be great if you guys can suggest me <strong>tools</strong> i should use to measure performance of two queries. Thanks a lot!</p>