By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,575 Members | 1,968 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,575 IT Pros & Developers. It's quick & easy.

Duplicate Entries

OuTCasT
100+
P: 374
I have a table with duplicated entries. How could i return the single rows of each record so i can get rid of the duplicates. Or how do i remove duplicate entry rows ?
Feb 20 '09 #1
Share this Question
Share on Google+
2 Replies


100+
P: 152
gpl
It all depends what you mean by duplicate
If you mean that there are several - but not all - columns that hold duplicate values, then you can use the non duplicate columns to uniquely identify the rows that you want to delete
However - if you have 2 or more rows with exactly the same content, then there is no way to distinguish between them, your only solution there is to store the values, delete all the rows with those values and then reinsert the row.
Feb 20 '09 #2

ck9663
Expert 2.5K+
P: 2,878
Or you can use DISTINCT keyword on your select.

Here's the complete syntax.


-- CK
Feb 20 '09 #3

Post your reply

Sign in to post your reply or Sign up for a free account.