select icdid,
               icdcode,
               his_icdid,
               lastflag,
               chimedflag,
               icdname,
               icdpym,
               icdwbm,
               orgid,
               del_flag,
               create_by,
               create_time,
               update_by,
               update_time,
               pid,
               guid
        from icd10
    
    
    
    
        insert into icd10
        
            icdcode,
            icdname,
            icdpym,
            icdwbm,
            orgid,
            del_flag,
            create_by,
            create_time,
            update_by,
            update_time,
            pid,
            guid,
            lastflag,
            chimedflag,
            his_icdid,
        
        
            #{icdcode},
            #{icdname},
            #{icdpym},
            #{icdwbm},
            #{orgid},
            #{delFlag},
            #{createBy},
            #{createTime},
            #{updateBy},
            #{updateTime},
            #{pid},
            #{guid},
            #{lastflag},
            #{chimedflag},
            #{hisIcdid},
        
    
    
        insert into icd10
        (
        icdcode,
        icdname,
        icdpym,
        icdwbm,
        orgid,
        del_flag,
        create_by,
        create_time,
        update_by,
        update_time,
        pid,
        guid,
        lastflag,
        chimedflag,
        his_icdid)
        VALUES
        
            (
            #{item.icdcode},
            #{item.icdname},
            #{item.icdpym},
            #{item.icdwbm},
            #{item.orgid},
            #{item.delFlag},
            #{item.createBy},
            #{item.createTime},
            #{item.updateBy},
            #{item.updateTime},
            #{item.pid},
            #{item.guid},
            #{item.lastflag},
            #{item.chimedflag},
            #{item.hisIcdid}
            )
        
    
    
        update icd10
        
            icdcode = #{icdcode},
            icdname = #{icdname},
            icdpym = #{icdpym},
            icdwbm = #{icdwbm},
            orgid = #{orgid},
            del_flag = #{delFlag},
            create_by = #{createBy},
            create_time = #{createTime},
            update_by = #{updateBy},
            update_time = #{updateTime},
            pid = #{pid},
            guid = #{guid},
            lastflag = #{lastflag},
            chimedflag = #{chimedflag},
            his_icdid = #{hisIcdid},
        
        where icdid = #{icdid}
    
    
        delete
        from icd10
        where icdid = #{icdid}
    
    
        delete from icd10 where icdid in
        
            #{icdid}