what is the difference between join and union?

Answers were Sorted based on User's Feedback



what is the difference between join and union?..

Answer / s

Join returns only rows that are qualified based on the Join
predicate. Whereas UNION retrieves both result sets above
and below the UNION operator and sorts to remove duplicates
before it returns the First row to the pgm

Is This Answer Correct ?    10 Yes 4 No

what is the difference between join and union?..

Answer / suresh ramaiyan

Join is used retrive the data from two or more tables.
Union is used to join the result of two queries.

Is This Answer Correct ?    7 Yes 5 No

what is the difference between join and union?..

Answer / lokesh chauhan

Join is used to established a conditional selection from 2
different tables, while union is used to select similar
data based on different conditions.

Is This Answer Correct ?    7 Yes 6 No

what is the difference between join and union?..

Answer / ananda kumar

join retrive the data more than one table using single sql
query where as union combine the results of two or more sql
queries.

Is This Answer Correct ?    2 Yes 2 No

Post New Answer

More DB2 Interview Questions

what is static sql? what is dynamic sql? Give me details

3 Answers  


Hi Everyone... Under the Logical files, when am working on multiple rec format logical file, I have joined two pf's using the multiple record format logical file concept, but when i run queried the LF only the first mentioned pf records are reflecting and I am not able to see any of the field records specified under the second pf. Kindly let me know whats the reason behind this. Below is the str of LF., R rec PFILE(LOGICAA) CUSTNO CUSTNAME BILL K CUSTNO R rec1 PFILE(LOGICAA1) CUSTNO ADD K CUSTNO .....

0 Answers  


Give a brief description of db2 isolation levels?

0 Answers  


What is null in db2?

0 Answers  


Can you tell me how can you find out the # of rows updated after an update statement?

0 Answers  






I need to view the number of tables existing under one particular Owner. Is it possible? If so, pl give the SQL query for this?

3 Answers  


How do I delete a table in database?

0 Answers  


how to copy the host variables from ps file into cobol program other than include statement

1 Answers   Syntel,


what is plan? is plan executable or package?

4 Answers  


why db2 is called as universal database?what is the storage capacity of db2v9 n what are the advantages of db2

3 Answers  


Mention the way of highlighting as well as putting a cursor to use in a cobol program.

0 Answers  


can I alter a table (e.g. adding a column) when other user is selecting some columns or updating some columns from the same table?

1 Answers  


Categories