Hi All,

I want to display all duplicate records in the table. My
query has to fetch all the records which are duplicate(First
Name or Last Name). Also I want the ability to also pull
names where there might be a middle initial placed in the
end of the first name field, (i.e., "Maria Z. " vs. "Maria")
as well.

Please guide me to find this.



Table:

ID FirstName LastName

1 Zach H Hoffman

2 Zach Hoffman

3 Troy Hoffman

4 Shawn Livermore

5 Prem S

6 Jony Hoffman H

7 Zach Modan



I need the query to filter.........

ID FirstName LastName

1 Zach H Hoffman

2 Zach Hoffman

3 Troy Hoffman

6 Jony Hoffman H

7 Zach Modan



I hope this example will give you clear idea.....




Thanks in Advance

Prem

Answer Posted / eralper

Hello Prem,
Please check the forum post
http://www.kodyaz.com/forums/thread/21123.aspx for solution
of your question. I see that you have asked this question
on several forums. That is a good idea to find an answer :)

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the status of services on passive node for failover cluster in sql server? : sql server database administration

835


Suggest a method of joining two tables.

809


Can you edit the .rdl code associated with a linked report?

121


what is raid? : Sql server database administration

717


What are the system database in sql server 2008?

731






How do use Having,Group by,Group function in SQL?

1533


How to add the custom code in Report?

112


What are the purposes and advantages stored procedure?

681


What is the use of sql profiler in sql server 2012?

661


What are types of scd? : sql server analysis services, ssas

725


How to convert a numeric expression from one data type to another?

697


How many types of dimensions are there and what are they? : sql server analysis services, ssas

774


if no size is defined while creating the database, what size will the database have? : Sql server administration

746


Explain error handling in ssis?

752


How do you troubleshoot errors in a SQL Server Agent Job?

744