delete from summary_infol_iu where id in
(select id from
(select id,
year,
month,
day,
t_type,
origin_country,
dec_qty,
dec_value,
row_number() over (partition by id) rows_num
from summary_infol_iu ) t
where t.rows_num >=2);
--根据img字段去重查出所有字段记录
--*可以改变成要查出的字段
select distinct on (img) * from dws_decl_d