Please let me know if UNION ALL and Natural Join does the
same operation and are same...
Answer Posted / subathra
union all: Joins the 2 selected results based on different
conditions.
Example:
select a.emp_id, b.dept_id from
emp a, dept b
where a.dept_id=b.dept_id
and a.sal < 3000
union all
select a.emp_id, b.dept_id from
emp a, dept b
where a.dept_id=b.dept_id
and a.sal > 6000
Natural Join: Establish the condition between 2 or more
tables.
Example: select a.emp_id, b.dept_id from
emp a, dept b
where a.dept_id=b.dept_id
| Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
Explain the savepoint statement.
What is database migration?
explain about mysql and its features. : Sql dba
What are the two different parts of the pl/sql packages?
What is pl sql code?
How to download oracle sql developer?
how to use 'mysql' to run sql statements? : Sql dba
What is the difference between an inner and outer join?
How do you explain an index number?
Are stored procedures faster than queries?
How would you convert date into julian date format?
How do you take the union of two tables in sql?
Which command is used to delete a package?
what is a control file ? : Sql dba
What is recursive stored procedure?