Top "Union" questions

Use this tag only for questions about UNION, a keyword of the SQL language for combining the results of multiple SQL queries.

MySQL: FULL OUTER JOIN - How do I merge one column?

I have a question regarding a FULL OUTER JOIN in MySQL. I have two (or more tables): table1 table2 id …

sql mysql union full-outer-join
How do you construct the union of two DFA's?

Does anyone have a straightforward description of the algorithm for constructing the union of two given DFA's? For example, say …

union transition finite-automata dfa
How can I add a column to this union result?

I have this query (which I removed some keys from for brevity's sake): SELECT id as in_id, out_id, …

mysql union
SQL Server: ORDER BY in subquery with UNION

i have two queries being combined with a UNION ALL1: --Query 1 SELECT Flavor, Color FROM Friends   --Query 2 SELECT Flavor, (SELECT …

sql-server sql-server-2000 sql-order-by union union-all
Conditional UNION in stored procedure

Bonjour! So, in a stored procedure I would like to do a conditional union decided by a parameter. How can …

sql sql-server union
Adding DISTINCT to a UNION query

How do I get distinct title.id's from this: SELECT Title.id, Title.title FROM titles as Title HAVING points &…

mysql sql union distinct union-all
How to properly union with set

I understand that any python set union with empty set would result in itself. But some strange behave I detect …

python python-2.7 for-loop set union
Perform union in mongoDB

I'm wondering how to perform a kind of union in an aggregate in MongoDB. Let's imaging the following document in …

mongodb aggregation-framework union
Same number of columns for Union Operation

I was going through union and union all logic and trying examples. What has puzzled me is why is it …

sql sql-server-2008-r2 union union-all
Append\Union two or several tables into one

I input 5 text data sets into R using read.table. Each data set has the same structure (100 rows, 50 cols). I …

r union read.table