SELECT <column1>, <column2>, <column3> FROM <table1> WHERE <condition1> UNION SELECT <column1>, <column2>, <column3> FROM <table1> WHERE <condition2>;
UNION on one table
SELECT <column1>, AVG(column2) FROM <table1> WHERE <condition1> GROUP BY <column1> UNION SELECT <column1>, AVG(column2) FROM <table2> WHERE <condition2> GROUP BY <column1>;
UNION on two tables
Use UNION to select the customer names, contact names and email addresses for customers in states 'IL', 'IN' or 'MI', as well as those for the company 'Fun4All' (4)
-- Oracle / MySQL / SQL Server SELECT cust_name, cust_contact, cust_email FROM Customers WHERE cust_state IN ('IL', 'IN', 'MI') UNION SELECT cust_name, cust_contact, cust_email FROM Customers WHERE cust_name = 'Fun4All';
| cust_name | cust_contact | cust_email |
| Village Toys | John Smith | sales@villagetoys.com |
| Fun4All | Jim Jones | jjones@fun4all.com |
| The Toy Store | Kim Howard | NULL |
| Fun4All | Denise L. Stephens | dstephens@fun4all.com |
SELECT prod_name FROM Products ORDER BY prod_name UNION SELECT cust_name FROM Customers ORDER BY cust_name;
Easter is celebrated on the first Sunday after the first full moon following the spring equinox. The course connects the celebration with the Sun and Moon, reflected in the names Sunday and Monday.
The spring and fertility goddess Ostara brings us to the rabbit, a symbol of fertility. From rabbit to hare, we arrive at the idea of Easter eggs laid by the Easter hare.
An Easter egg can also be a joke or hidden message in software, a film or a website. Like real Easter eggs, these features are hidden and must be found. Now that you have found one, click it! All exercise answers will become visible. Returning to the Welcome page hides your Easter egg again.