Answers for "sql duplicates with two columns"

SQL
0

sql select duplicates based on two columns

select s.id, t.* 
from [stuff] s
join (
    select name, city, count(*) as qty
    from [stuff]
    group by name, city
    having count(*) > 1
) t on s.name = t.name and s.city = t.city
Posted by: Guest on October-10-2021

Code answers related to "sql duplicates with two columns"

Code answers related to "SQL"

Browse Popular Code Answers by Language