title: UNION with WHERE clause
body: <p>I'm doing a <code>UNION</code> of two queries on an Oracle database. Both of them have a <code>WHERE</code> clause. Is there a difference in the performance if I do the <code>WHERE</code> after <code>UNION</code>ing the queries compared to performing the <code>UNION</code> after <code>WHERE</code> clause?</p>
  
  <p>For example:</p>
  
  <pre><code>SELECT colA, colB FROM tableA WHERE colA &gt; 1
  UNION
  SELECT colA, colB FROM tableB WHERE colA &gt; 1
  </code></pre>
  
  <p>compared to:</p>
  
  <pre><code>SELECT * 
    FROM (SELECT colA, colB FROM tableA
          UNION
          SELECT colA, colB FROM tableB) 
   WHERE colA &gt; 1
  </code></pre>
  
  <p>I believe in the second case, it performs a full table scan on both the tables affecting the performance. Is that correct?</p>