title: Joining two given set of queries in mysql
body: <p>I have two queries which are giving me a desired result.is there any chance to combine them into one. the queries are below: The first query is below:</p>
  
  <pre><code>SELECT c.cy_id,
         c.to_id AS tsn,
         se.x AS tX,
         se.y AS ty
  FROM c
  JOIN se ON c.to_id = se.ar
  UNION
  SELECT c.cy_id,
         c.to_id AS tsn,
         swt.x AS tx,
         swt.y AS tY
  FROM c
  JOIN swt ON c.to_id = swt.ar
  </code></pre>
  
  <p>The second query is</p>
  
  <pre><code>SELECT c.cy_id,
         c.fr_id AS fsn,
         se.x AS fX,
         se.y AS fy
  FROM c
  JOIN se ON c.fr_id = se.ar
  </code></pre>
  
  <p>Can I join both the queries and get the combined results with all the column names.</p>