HRMS Employee’s Performance API
HRMS Employee’s Performance API
DECLARE x_validate BOOLEAN := FALSE; x_performance_review_id NUMBER; x_person_id NUMBER; x_event_id NUMBER; x_review_date DATE; x_performance_ratg VARCHAR2 (300); x_next_perf_review_date DATE; x_attribute_category VARCHAR2 (300); x_attribute1 VARCHAR2 (300); x_attribute2 VARCHAR2 (300); x_attribute3 VARCHAR2 (300); x_attribute4 VARCHAR2 (300); x_attribute5 VARCHAR2 (300); x_attribute6 VARCHAR2 (300); x_attribute7 VARCHAR2 (300); x_attribute8 VARCHAR2 (300); x_attribute9 VARCHAR2 (300); x_attribute10 VARCHAR2 (300); x_attribute11 VARCHAR2 (300); x_attribute12 VARCHAR2 (300); x_attribute13 VARCHAR2 (300); x_attribute14 VARCHAR2 (300); x_attribute15 VARCHAR2 (300); x_attribute16 VARCHAR2 (300); x_attribute17 VARCHAR2 (300); x_attribute18 VARCHAR2 (300); x_attribute19 VARCHAR2 (300); x_attribute20 VARCHAR2 (300); x_attribute21 VARCHAR2 (300); x_attribute22 VARCHAR2 (300); x_attribute23 VARCHAR2 (300); x_attribute24 VARCHAR2 (300); x_attribute25 VARCHAR2 (300); x_attribute26 VARCHAR2 (300); x_attribute27 VARCHAR2 (300); x_attribute28 VARCHAR2 (300); x_attribute29 VARCHAR2 (300); x_attribute30 VARCHAR2 (300); x_object_version_number NUMBER; x_next_review_date_warng BOOLEAN; v_error VARCHAR2 (3000); v_seq NUMBER; CURSOR c IS SELECT * FROM xx_perf; BEGIN FOR c1_rec IN c LOOP SELECT per_performance_reviews_s.NEXTVAL INTO v_seq FROM DUAL; <hr class="system-pagebreak" /> BEGIN hr_perf_review_api.create_perf_review (p_validate => x_validate, p_performance_review_id => v_seq, p_person_id => c1_rec.person_id, p_event_id => x_event_id, p_review_date => c1_rec.review_date, p_performance_rating => c1_rec.grade, p_next_perf_review_date => x_next_perf_review_date, p_attribute_category => x_attribute_category, p_attribute1 => x_attribute1, p_attribute2 => x_attribute2, p_attribute3 => x_attribute3, p_attribute4 => x_attribute4, p_attribute5 => x_attribute5, p_attribute6 => x_attribute6, p_attribute7 => x_attribute7, p_attribute8 => x_attribute8, p_attribute9 => x_attribute9, p_attribute10 => x_attribute10, p_attribute11 => x_attribute11, p_attribute12 => x_attribute12, p_attribute13 => x_attribute13, p_attribute14 => x_attribute14, p_attribute15 => x_attribute15, p_attribute16 => x_attribute16, p_attribute17 => x_attribute17, p_attribute18 => x_attribute18, p_attribute19 => x_attribute19, p_attribute20 => x_attribute20, p_attribute21 => x_attribute21, p_attribute22 => x_attribute22, p_attribute23 => x_attribute23, p_attribute24 => x_attribute24, p_attribute25 => x_attribute25, p_attribute26 => x_attribute26, p_attribute27 => x_attribute27, p_attribute28 => x_attribute28, p_attribute29 => x_attribute29, p_attribute30 => x_attribute30, p_object_version_number => x_object_version_number, p_next_review_date_warning => x_next_review_date_warng ); COMMIT; UPDATE xx_perf SET valide_flag = 'DONE' WHERE person_id = c1_rec.person_id; COMMIT; EXCEPTION WHEN OTHERS THEN v_error := SQLERRM; UPDATE xx_perf SET valide_flag = 'ERORR', err_msg = v_error WHERE person_id = c1_rec.person_id; END; END LOOP; END;