select sbr.*, bs.manage_tags as manageTags, bsv.id as varietyId, bsv.variety as varietyName, '乳房评分' as event_type, sf.id as sheepfoldId, sf.sheepfold_name as sheepfoldName, sbr.event_date from sc_breast_rating sbr left join bas_sheep bs on sbr.sheep_id = bs.id left join bas_sheep_variety bsv on bs.variety_id = bsv.id left join da_sheepfold sf on bs.sheepfold_id = sf.id insert into sc_breast_rating sheep_id, event_date, depth, length, position, adbere, spacing, score, comment, technician, create_by, create_time, #{sheepId}, #{eventDate}, #{depth}, #{length}, #{position}, #{adbere}, #{spacing}, #{score}, #{comment}, #{technician}, #{createBy}, #{createTime}, update sc_breast_rating sheep_id = #{sheepId}, event_date = #{eventDate}, depth = #{depth}, length = #{length}, position = #{position}, adbere = #{adbere}, spacing = #{spacing}, score = #{score}, comment = #{comment}, technician = #{technician}, create_by = #{createBy}, create_time = #{createTime}, where id = #{id} delete from sc_breast_rating where id = #{id} delete from sc_breast_rating where id in #{id}