Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Delete record

User_JIAY3Jul 29 2013 — edited Jul 29 2013

Hi,

Created three tables and group by 3 tables column name. want to delete duplicate record without first table(test).

Delete the duplicate record in test1 and test2 except test. kindly help me.

SELECT a as Name,b as M_Name, c as L_Name, count(*)

  FROM (

        SELECT first_name as a, middle_name as b, last_name as c FROM test

        UNION ALL

        SELECT first_name as a, middle_name as b, last_name as c FROM test1

        UNION ALL

        SELECT first_name as a, middle_name as b, last_name as c FROM test2

       ) as count

GROUP BY a,b,c

HAVING count(*) > 1

Comments

Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Aug 26 2013
Added on Jul 29 2013
6 comments
528 views