t.unit_id as unitId,
t.repo_id as repoId,
t.unit_name as unitName
t.repo_id = #{repoId} AND
t.unit_name = #{unitName} AND
insert into t_repo_unit
repo_id,
unit_id,
unit_name,
#{repoId},
#{unitId},
#{unitName},
update t_repo_unit
repo_id=#{repoId},
unit_name=#{unitName},
where unit_id=#{unitId}
update t_repo_unit
SET is_use = 0
where unit_id=#{unitId}
delete from t_repo_unit
where unit_id=#{unitId}
delete from t_repo_unit
where repo_id=#{repoId}