left join sys_user u on u.user_name=a.create_by
left join sys_dept d on u.dept_id = d.dept_id
left join bid q on q.bid_id = a.bid_id
left join bid_jsqr j on j.bid_jsqr_id = a.bid_jsxz_confirm_id
select a.bid_hj_id, a.bid_hj_code, a.bid_hj_pricing_type, a.bid_hj_pricing_date, a.bid_hj_remark,
a.create_by, a.create_time, a.update_by, a.update_time,
u.nick_name create_name,
a.bid_hj_approval_status,q.bid_id,q.bid_code,q.bid_salesman_name,
q.bid_tendering_unit,q.bid_project,
j.bid_jsqr_id bid_jsxz_confirm_id,j.bid_jsxz_group_values,
j.bid_jsqr_tl_approval_status,j.bid_jsqr_tl_remark,
j.bid_jsqr_dy_approval_status,j.bid_jsqr_dy_remark,
j.bid_jsqr_zy_approval_status,j.bid_jsqr_zy_remark,
j.bid_jsqr_qt_approval_status,j.bid_jsqr_qt_remark,
a.bid_jsqr_check_state,a.bid_jsqr_check_info
from bid_hj a
insert into bid_hj
bid_hj_id,
bid_hj_code,
bid_hj_approval_status,
bid_hj_pricing_type,
bid_hj_pricing_date,
bid_hj_remark,
create_by,
create_time,
update_by,
update_time,
bid_id,
bid_jsxz_confirm_id,
bid_jsqr_check_state,
bid_jsqr_check_info,
#{bidHjId},
#{bidHjCode},
#{bidHjApprovalStatus},
#{bidHjPricingType},
#{bidHjPricingDate},
#{bidHjRemark},
#{createBy},
#{createTime},
#{updateBy},
#{updateTime},
#{bidId},
#{bidJsxzConfirmId},
#{bidJsqrCheckState},
#{bidJsqrCheckInfo},
update bid_hj
bid_hj_code = #{bidHjCode},
bid_hj_approval_status = #{bidHjApprovalStatus},
bid_hj_pricing_type = #{bidHjPricingType},
bid_hj_pricing_date = #{bidHjPricingDate},
bid_hj_remark = #{bidHjRemark},
create_by = #{createBy},
create_time = #{createTime},
update_by = #{updateBy},
update_time = #{updateTime},
bid_jsqr_check_state = #{bidJsqrCheckState},
bid_jsqr_check_info = #{bidJsqrCheckInfo},
where bid_hj_id = #{bidHjId}
delete from bid_hj where bid_hj_id = #{bidHjId}
delete from bid_hj where bid_hj_id in
#{bidHjId}