title: MySQL; Get information from 3 table same time
body: <p>People</p>
  
  <p>here is my little problem.
  I have three table:
  a_names_1
  b_names_2
  c_names_3 
  they are same by structure. all of them has two item: name and used</p>
  
  <p>Is there any QUERY to run to get and count all the 'name' that has 'used'=1 from all those three tables together.</p>
  
  <p>I've tried this one, but didn't work: </p>
  
  <pre><code>(SELECT COUNT(*) 'name' from a_names_1) UNION 
  (SELECT COUNT(*) 'name' from a_names_2) UNION 
  (SELECT COUNT(*) 'name' from a_names_3) WHERE `used`=1
  </code></pre>
  
  <p>I'm using PHPMyAdmin for MySQL.</p>
  
  <p>Any Help would be appreciated.. thanks in advance</p>