Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9090277
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T22:20:14+00:00 2026-06-16T22:20:14+00:00

I believe my question was asked on SO, but I didn’t find the answer.

  • 0

I believe my question was asked on SO, but I didn’t find the answer.

There is a mysql table mytable with one column mycolumn.

What is the mysql query to remove duplicates from a table?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T22:20:15+00:00Added an answer on June 16, 2026 at 10:20 pm

    Only one column without pk or another column that you can use for see if they are different?
    if yes, this is a bad practice. Consider inserting a new column (number) and insert id for every record, than you can try this query:

    delete from table 
    where counter > 1 and inner_query.mycolumn = table.mycolumn and inner_query.col_id = table.col_id from 
    (select mycolumn, col_id, count (mycolumn) counter  
     from table group by  mycolumn
    ) inner_query
    

    than, you can add a primary key

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I believe this question has been asked here for a while but there wasn't
I know this question as been asked countless times, but believe me I've searched
This is driving me nuts. I believe I asked this exact same question, but
I am sorry, for I believe that this question has been asked already, but
I know that this question might have been asked like 100 times, but, believe
It's hard to believe this question hasn't been asked or is not possible, but
I believe that this question has been asked in a few different forms, but
I have previously asked two questions Question 1 and Question 2 but there is
I originally asked a related question here , but didn't really seem to get
The question was asked but deleted by the asker before it received an answer.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.