473,396 Members | 1,693 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Delete duplicate record

How to delete duplicate record from a table without using cursor
if any one know the answer please tell me
sandeep kumar pradhan
Jan 11 '08 #1
2 1392
amitpatel66
2,367 Expert 2GB
How to delete duplicate record from a table without using cursor
if any one know the answer please tell me
sandeep kumar pradhan
Sandeep,

Can you please post what you have tried so far?

Please post your table structure also
Jan 11 '08 #2
ck9663
2,878 Expert 2GB
How to delete duplicate record from a table without using cursor
if any one know the answer please tell me
sandeep kumar pradhan

if it's a full duplicate records (multiple records with the same values in columns)...simple do a:

Expand|Select|Wrap|Line Numbers
  1.  select distinct * from mytable
...

this will not remove your duplicate. it will just show you your table, without the duplicate....you can then

Expand|Select|Wrap|Line Numbers
  1. select distinct * into mytemptable from mytable
  2.  
you now have a mytemptable that contains only unique records...whether you will drop the mytable and rename mytemptable to mytable, or you can just leave it for analysis...etc...

-- CK
Jan 11 '08 #3

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

Similar topics

2
by: Barbara | last post by:
Hi, I have an sql database that has the primary key set to three fields, but has not been set as unique(I didn't create the table). I have 1 record that has 2 duplicates and I am unable to delete...
2
by: ms | last post by:
Access 2000: I am trying to delete duplicate records imported to a staging table leaving one of the duplicates to be imported into the live table. A unique record is based on a composite key of 3...
1
by: Charles | last post by:
Hi MS Access & MS SQL Server Gurus ! I am trying to delete duplicate data from a LINKED SQL Server 2000 table (LinkedTable) and insert the result into a local (in Access) table. The following...
4
by: KT | last post by:
Is there any one click solution that would do the trick? I would like to create a button, so the person who maintains the database can perform clean up work to delete duplicate records which...
6
by: Karl Richards | last post by:
I am attempting to delete duplicate rows in a spreadsheet using the Excel object. Does anyone have any idea how to do this? I've looked everywhere that I can find on the Web and have not been...
2
by: mcasaurabhsumit | last post by:
Hello Friend, I am sumit saurabh. I am doing MCA from IGNOU. Can you plz. Help me to write a query------- How to delete duplicate Records from a table using single statement. Note: one Record...
3
by: rajeshkrsingh | last post by:
Hi friends, Step1- create table duplicate ( intId int, varName varchar(50) ) insert into duplicate(intId,varName) values(1,'rajesh') insert into duplicate(intId,varName) values(2,'raj12')...
7
by: AccessHunter | last post by:
I am using the following code to find and delete records in a table. The logic will go through each record and if a duplicate row is found will delete it. I ran this code and it worked the first...
1
by: kimmccain | last post by:
I have a form with two buttons, Completed and Pended. When the completed button is clicked, the record is moved to the completed table and the form's record is decreased by 1. When the pended...
3
allingame
by: allingame | last post by:
Need help with append and delete duplicates I have tables namely 1)emp, 2)time and 3)payroll TABLE emp ssn text U]PK name text
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.