DBMS Lab Experiment 4
DBMS Lab Experiment 4
mysql -u root -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 6
Server version: 5.7.33-0ubuntu0.16.04.1 (Ubuntu)
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> select
* from
student union
select * from
raja;
+------+---------+------+
| name | city | age |
+------+---------+------+
| ram | puri | 20 |
| ravi | bbsr | 21 |
| hari | kolkata | 22 |
| raj | kdp | 23 |
| mili | aul | 20 |
| rina | puri | 21 |
+------+---------+------+
6 rows in set (0.00 sec)
mysql> select * from student union all select * from raja;
+------+---------+------+
| name | city | age |
+------+---------+------+
| ram | puri | 20 |
| ravi | bbsr | 21 |
| hari | kolkata | 22 |
| ram | puri | 20 |
| ravi | bbsr | 21 |
| raj | kdp | 23 |
| mili | aul | 20 |
| rina | puri | 21 |
+------+---------+------+
8 rows in set (0.00 sec)