SELECT id, resume, organization_name, contact_number, departmental_application, create_time, update_time, parent_id, update_user_id, (select user_name from automessage_sys_user where user_id=automessage_organization_chart.update_user_id) as updateUserName, (select organization_name from automessage_organization_chart as oc where oc.id=automessage_organization_chart.parent_id) as parentName, city, district, village, (select name from automessage_area_code_2022 where city=automessage_area_code_2022.code) as cityName, (select name from automessage_area_code_2022 where district=automessage_area_code_2022.code) as districtName, (select name from automessage_area_code_2022 where village=automessage_area_code_2022.code) as villageName, detailed_address, grade, area_list FROM automessage_organization_chart insert into automessage_organization_chart ( id, organization_name, parent_id, city, district, village, detailed_address, grade, area_list, contact_number, departmental_application, update_user_id, resume, update_time, create_time )values( #{id}, #{organizationName}, #{parentId}, #{city}, #{district}, #{village}, #{detailedAddress}, #{grade}, #{areaList}, #{contactNumber}, #{departmentalApplication}, #{updateUserId}, #{resume}, sysdate(), sysdate() ) update automessage_organization_chart id=#{id}, organization_name=#{organizationName}, parent_id=#{parentId}, city=#{city}, district=#{district}, village=#{village}, detailed_address=#{detailedAddress}, grade=#{grade}, departmental_application=#{departmentalApplication}, update_user_id=#{updateUserId}, area_list=#{areaList}, contact_number=#{contactNumber}, departmental_application=#{departmentalApplication}, update_user_id=#{updateUserId}, resume=#{resume}, update_time=sysdate() where id= #{id} delete from automessage_organization_chart where id= #{Id}