how to delete duplicate rows in sql server2005

Answer Posted / apps

select distinct eno,ename into temp_table from main_table
drop table main_table
-----
sp_rename temp_table,main_table

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to change the data type of an existing column with "alter table" statements in ms sql server?

525


What is a trigger? Why we need it?

529


What is snapshot replication?

589


What is normalization and denormalization in sql server?

535


Explain data warehousing in sql server?

602






how to create a scrollable cursor with the scroll option? : Sql server database administration

605


How to stop log file growing too big?

571


Can one drop a column from a table?

545


What do you understand by replication in sql server? Mention the different types of replication in sql server.

500


Where the sql logs gets stored?

537


What is the largest component inside a field?

527


Explain datetimeoffset data type in sal server 2008?

530


What are the difference between “where” and “having” clause in sql server?

579


Do you know query execution plan?

582


What is recompile sql server?

561