I have a mysql table that looks like this:
id int(11) autoincrement
artist varchar(50)
title varchar(50)
I need to check for any rows that have the same titles.
So for example, if I had the following rows:
1 - Bob - Hello World
2 - Charlie Brown - Theme Song
3 - Joe - Hello World
4 - Joe - Is Cool
5 - Bob - Magic Dude
The query would display Row 1, and Row 3 as duplicates. Any idea how I can do something like this?
deleting rows with same value in a single column
Moderator: General Moderators
Re: deleting rows with same value in a single column
Code: Select all
SELECT * FROM `table` GROUP BY `title` HAVING COUNT(1) > 1