比如我要删除我cities_airportrunway这张表中runway_number,runway_ref_airport_id这两个字段内容重复的数据,删除重复的只留一条。sql我可以这样写:
delete from cities_airportrunway where id not in (select min(id) from cities_airportrunway
group by runway_number,runway_ref_airport_id)
比如我要删除我cities_airportrunway这张表中runway_number,runway_ref_airport_id这两个字段内容重复的数据,删除重复的只留一条。sql我可以这样写:
delete from cities_airportrunway where id not in (select min(id) from cities_airportrunway
group by runway_number,runway_ref_airport_id)