Home » SQL & PL/SQL » SQL & PL/SQL » Comparing two tables with no matching keys in PL/SQL
Comparing two tables with no matching keys in PL/SQL [message #221043] Fri, 23 February 2007 07:20 Go to next message
ranjith_taurean
Messages: 1
Registered: February 2007
Junior Member
Hi All,

Straight to the point. My requirement is as follows:

I've two database tables(say A and B) with different structure. But i've six fields, which are common in both the tables. These two tables are not related to each other(I mean there is no common key, between the two tables). I've to compare Table A with Table B and i've to list the rows which are in A, but not in B. In a similar manner, i;'I've to compare table B with Table A and list all the rows, which are in B, but not in A. Finally, if there is a mismatch in some of the columns between the two tables, i want to list both the rows in the two tables.

Seems very complex to me. Hope you guys, understand what i mean above.

Thanks in Anticipation.

Thanks n Regards
Re: Comparing two tables with no matching keys in PL/SQL [message #221060 is a reply to message #221043] Fri, 23 February 2007 09:34 Go to previous message
smartin
Messages: 1803
Registered: March 2005
Location: Jacksonville, Florida
Senior Member
Look into sql set operators (minus, intersect, union, union all)
Previous Topic: problem with order by
Next Topic: SQL Query Help - Analytic Query
Goto Forum:
  


Current Time: Sun Dec 04 20:44:40 CST 2016

Total time taken to generate the page: 0.13580 seconds