INSERT INTO study_task(study_task_name,study_object,publish_user,publish_time,create_time,create_user,publish_status) VALUES ( #{studyTaskName},#{studyObject},#{publishUser},#{publishTime},#{createTime},#{createUser},#{publishStatus} ) INSERT INTO study_people(study_object,user_name,nick_name,study_id) VALUES ( #{studyObject},#{userName},#{nickName},#{studyId} ) INSERT INTO study_file(task_id,file_name,file_url,file_previous_name,file_size,file_url_new) VALUES ( #{taskId},#{fileName},#{fileUrl},#{filePreviousName},#{fileSize},#{fileUrlNew} ) INSERT INTO study_details(study_id,study_people_id,file_name) VALUES ( #{studyId},#{studyPeopleId},#{fileName} ) update study_task ,study_task_name = #{studyTaskName} ,study_object = #{studyObject} ,publish_status = #{publishStatus} ,publish_user = #{publishUser} ,publish_time = #{publishTime} WHERE id=#{id} update study_details set study_status='1' where id=#{id} update study_people set study_status=#{studyStatus} where id=#{studyPeopleId} delete from study_task where id = #{id} delete from study_people where study_id = #{studyId} delete from study_file where task_id = #{taskId} delete from study_details where study_id = #{studyId} and study_people_id = #{id} delete from study_file where file_url = #{fileUrl}