oracle数据库表去重

对R_CODE、USER_CODE两个字段进行选择,或者多个字段。去除表中重复数据

delete from USERS_02 a where a.rowid! = (

    select max(b.rowid) from USERS_02  b

    where a.R_CODE =b.R_CODE and a.USER_CODE = b.USER_CODE

你可能感兴趣的:(oracle数据库表去重)