Please let me know if UNION ALL and Natural Join does the
same operation and are same...

Answer Posted / vikneswaran

no,union all and natural join is not same. for example tave
two tame emp and dept

emp table

empid ename salary
1 a 1000
2 b 2000

dept table
deptid deptno
1 10
2 20
if i join this two tables
(empid = deptid)

empid ename salary deptno
1 a 1000 10
2 b 2000 20

if i union a11 this two tables

empid ename salary deptno
1 a 1000 null
2 b 2000 null
1 null null 10
2 null null 20
so join and unionall is not same

Is This Answer Correct ?    9 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can we optimize a sql query?

567


What is file based approach?

483


Can we connect to postgresql using sql developer?

480


What does subquery mean in sql?

530


How do you break a loop in pl sql?

516






explain the difference between myisam static and myisam dynamic. : Sql dba

506


What is the purpose of the sql select top clause?

539


What is data modelling in sql?

514


What is cursor and why it is required?

543


How much does sql cost?

512


Define SQL and state the differences between SQL and other conventional programming Languages?

671


Are stored procedures faster than queries?

514


what is cursor. write example of it. What are the attributes of cursor.

736


Which command is used to delete a package?

572


What is Collation Sensitivity ? What are the various type ?

487