Jump to content

How to find duplicate records from a join table ?


Recommended Posts

Hi all, I want to find duplicate records from a joint table result (The two tables are from two different DB's). Bellow are the tables and my requirement. Table1 from DB D1EmpID205205205206207207208209210211 Table2 from DB D2PayID205206207 208 209 210 211 i have joined these two tables on the basis of EmpID = PAYID and got the following result SELECT T1.EMPID,T2.PAYIDFROM D1.table1 T1INNERJOIN D2.table2 T2 onT1.EMPID collate Latin1_General_CI_AI =T2.PayID EmpID PayID 205 205 205 205 205 205206 206207 207207 207208 208209 209210 210211 211 In this result 205 and 207 having duplicate, so i want a query to display the duplicate entries .

Edited by raghugnair
Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...