t.id as id,
t.check_id as checkId,
t.file as file
t.check_id = #{checkId} AND
t.file = #{file} AND
insert into t_check_device_file
check_id,
file,
id,
#{checkId},
#{file},
#{id},
update t_check_device_file
check_id=#{checkId},
file=#{file},
where id=#{id}
update t_check_device_file
SET is_use = 0
where id=#{id}
delete from t_check_device_file
where id=#{id}
delete from t_check_device_file
where check_id=#{checkId}