select id,
tagcategoryid,
tagid,
orgid,
del_flag,
update_by,
update_time,
create_by,
create_time,
isupload,
upload_time,
tagname,
guid,
patid
from pat_archivetag
insert into pat_archivetag
tagcategoryid,
tagid,
tagname,
orgid,
del_flag,
update_by,
update_time,
create_by,
create_time,
isupload,
upload_time,
patid,
guid,
#{tagcategoryid},
#{tagid},
#{tagname},
#{orgid},
#{delFlag},
#{updateBy},
#{updateTime},
#{createBy},
#{createTime},
#{isupload},
#{uploadTime},
#{patid},
#{guid},
update pat_archivetag
tagcategoryid = #{tagcategoryid},
tagid = #{tagid},
tagname = #{tagname},
orgid = #{orgid},
del_flag = #{delFlag},
update_by = #{updateBy},
update_time = #{updateTime},
create_by = #{createBy},
create_time = #{createTime},
isupload = #{isupload},
upload_time = #{uploadTime},
patid = #{patid},
guid = #{guid},
where id = #{id}
update pat_archivetag
del_flag = #{delFlag},
and tagid = #{tagid}
and patid = #{patid}
delete from pat_archivetag where id in
#{id}