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