in tabase table having a column in it empname field is
there which having 5 duplicate values is there i want
deleted all the duplicates i want showing only one name
only.
Answer Posted / venkat
Hope this methodology would help you better
1.Create a temp table
2.Select duplicated row's empid,empname into the temp table.
3.Create a cursor by selecting values from temp table.
4.Keep either min or max(empid) from original table and
delete the rest of the duplicated rows.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What are the different Topologies in which Replication can be configured?
How to locate and take substrings with charindex() and substring() functions?
Your sql server is running out of disk space. You notice that there are several large files with ldf extensions what are these files?
How to enter binary string literals in ms sql server?
What is primary key index?
Explain the steps to create and execute a user-defined function in the sql server?
What are window functions in sql server?
What are the source of constraints?
Can you roll back the ddl statement in a trigger?
Can I run multiple instances of sql server 2000 at the same time on one computer?
Explain Capacity planning to create a database? and how to monitor it?
What is sql server profiler trace data file?
What are recommended options to be used while using db mirroring? : sql server database administration
Explain the rules for designing files and file groups in sql server?
Explain DBCC?