public String insertSelective(StudentLogAssign record) { BEGIN(); INSERT_INTO("student_log_assign"); if (record.getAssignId() != null) { VALUES("assign_id", "#{assignId,jdbcType=BIGINT}"); } if (record.getStudentId() != null) { VALUES("student_id", "#{studentId,jdbcType=BIGINT}"); } if (record.getDepartCode() != null) { VALUES("depart_code", "#{departCode,jdbcType=CHAR}"); } if (record.getDepartName() != null) { VALUES("depart_name", "#{departName,jdbcType=VARCHAR}"); } if (record.getJobCode() != null) { VALUES("job_code", "#{jobCode,jdbcType=CHAR}"); } if (record.getJobName() != null) { VALUES("job_name", "#{jobName,jdbcType=VARCHAR}"); } if (record.getJobDays() != null) { VALUES("job_days", "#{jobDays,jdbcType=INTEGER}"); } if (record.getJobDeadline() != null) { VALUES("job_deadline", "#{jobDeadline,jdbcType=DATE}"); } if (record.getAssignedTo() != null) { VALUES("assigned_to", "#{assignedTo,jdbcType=VARCHAR}"); } if (record.getCreateTime() != null) { VALUES("create_time", "#{createTime,jdbcType=TIMESTAMP}"); } if (record.getCreateUser() != null) { VALUES("create_user", "#{createUser,jdbcType=VARCHAR}"); } return SQL(); }
public String updateByExampleSelective(Map<String, Object> parameter) { StudentLogAssign record = (StudentLogAssign) parameter.get("record"); StudentLogAssignExample example = (StudentLogAssignExample) parameter.get("example"); BEGIN(); UPDATE("student_log_assign"); if (record.getAssignId() != null) { SET("assign_id = #{record.assignId,jdbcType=BIGINT}"); } if (record.getStudentId() != null) { SET("student_id = #{record.studentId,jdbcType=BIGINT}"); } if (record.getDepartCode() != null) { SET("depart_code = #{record.departCode,jdbcType=CHAR}"); } if (record.getDepartName() != null) { SET("depart_name = #{record.departName,jdbcType=VARCHAR}"); } if (record.getJobCode() != null) { SET("job_code = #{record.jobCode,jdbcType=CHAR}"); } if (record.getJobName() != null) { SET("job_name = #{record.jobName,jdbcType=VARCHAR}"); } if (record.getJobDays() != null) { SET("job_days = #{record.jobDays,jdbcType=INTEGER}"); } if (record.getJobDeadline() != null) { SET("job_deadline = #{record.jobDeadline,jdbcType=DATE}"); } if (record.getAssignedTo() != null) { SET("assigned_to = #{record.assignedTo,jdbcType=VARCHAR}"); } if (record.getCreateTime() != null) { SET("create_time = #{record.createTime,jdbcType=TIMESTAMP}"); } if (record.getCreateUser() != null) { SET("create_user = #{record.createUser,jdbcType=VARCHAR}"); } applyWhere(example, true); return SQL(); }