How to Upload Establishment in Employee Qualification in Oracle HRMS

Navigation: Global HRMS Manager --> People --> Enter and Maintain --> Others --> Qualifications


How to Upload Establishment in Employee Qualification in Oracle HRMS

Question is: Where would this List of values (LOV) populate from??

Solution:

Navigation: Global HRMS Manager --> Career Management --> Schools and Colleges


How to Upload Establishment in Employee Qualification in Oracle HRMS

But LOV would still not populate, so what to do now??

Navigate to: Global HRMS Manager --> People --> Enter and Maintain --> Others --> Schools and Colleges Attended

Manual Process:

Select a value from list of values and press save.

How to Upload Establishment in Employee Qualification in Oracle HRMS

As you can see, list of values of Establishment has been populated.

How to Upload Establishment in Employee Qualification in Oracle HRMS

Using Procedure:

TABLE


CREATE TABLE DEV_ESTAB_ATTEND
(
  LINE_ID                NUMBER,
  EMP_NUM                VARCHAR2(240 BYTE),
  EFFECTIVE_DATE         DATE,
  FULL_TIME              VARCHAR2(240 BYTE),
  EST_NAME               VARCHAR2(240 BYTE),
  ATTENDED_START_DATE    DATE,
  ATTENDED_END_DATE      DATE,
  EST_PROCESS_FLAG       CHAR(1 BYTE),
  EST_ERROR_DESCRIPTION  VARCHAR2(240 BYTE),
  EST_ID                 NUMBER,
  EST_DEFINITION_ID      NUMBER,
  EST_OBJ_VER_NUMBER     NUMBER

);


PROCEDURE

CREATE OR REPLACE PROCEDURE APPS.dev_create_estab_attend
IS
   CURSOR c_est
   IS
      SELECT line_id, emp_num, effective_date, est_name, full_time,
             attended_start_date, attended_end_date, est_process_flag,
             est_error_description, est_id, est_definition_id,
             est_obj_ver_number
        FROM dev_estab_attend;
       
       /*WHERE NVL (est_process_flag, 'N') <> 'Y'
         AND est_error_description IS NULL;*/

   lc_c_est                  c_est%ROWTYPE;
   l_object_version_number   NUMBER;
   l_attendance_id           NUMBER;
   l_establishment_id        NUMBER;
   error_desc                VARCHAR2 (240);
   l_att_effective_date      DATE;
   l_person_id               NUMBER;
   lv_est_flag               CHAR (1);
   l_seq                     VARCHAR2 (20);
BEGIN
   OPEN c_est;

   LOOP
      FETCH c_est
       INTO lc_c_est;

      EXIT WHEN c_est%NOTFOUND;

---------------------------
-- Person ID
---------------------------
      SELECT papf.effective_start_date, papf.person_id
        INTO l_att_effective_date, l_person_id
        FROM per_all_people_f papf
       WHERE papf.employee_number = lc_c_est.emp_num
         and sysdate between papf.effective_start_date and papf.effective_end_date;
        
---------------------------
-- Establishment ID
---------------------------
        
      SELECT pe.establishment_id
      INTO l_establishment_id
      FROM per_establishments pe
     WHERE UPPER (pe.NAME) = UPPER (lc_c_est.est_name);
        

      BEGIN
         per_estab_attendances_api.create_attended_estab
              (p_validate                   => FALSE,
               p_effective_date             => l_att_effective_date,
               p_business_group_id          => 2217,
               p_fulltime                   => lc_c_est.full_time,
                                                          -- use YES_NO lookup
               --p_establishment              => lc_c_est.est_name,
                                                     -- if est not exist in DB
               p_establishment_id           => l_establishment_id , -- if est exist in DB
               p_person_id                  => l_person_id,
               p_attended_start_date        => lc_c_est.attended_start_date,
               p_attended_end_date          => lc_c_est.attended_end_date,
               p_attendance_id              => l_attendance_id,
               p_object_version_number      => l_object_version_number
              );

         IF l_attendance_id IS NOT NULL
         THEN
            lv_est_flag := 'Y';
            error_desc := 'No Error';
         END IF;

         IF lv_est_flag = 'Y'
         THEN
            UPDATE dev_estab_attend
               SET est_error_description = error_desc,
                   est_process_flag = lv_est_flag,
                   est_obj_ver_number = l_object_version_number
             WHERE line_id = lc_c_est.line_id;
         ELSE
            error_desc := error_desc || SQLERRM;

            UPDATE dev_estab_attend
               SET est_error_description = error_desc,
                   est_process_flag = 'N'
             WHERE line_id = lc_c_est.line_id;
         END IF;

         DBMS_OUTPUT.put_line ('est ID    : ' || l_attendance_id);
      EXCEPTION
         WHEN OTHERS
         THEN
            lv_est_flag := 'N';
            error_desc := error_desc || SQLERRM;

            UPDATE dev_estab_attend
               SET est_error_description = error_desc,
                   est_process_flag = lv_est_flag
             WHERE line_id = lc_c_est.line_id;

            DBMS_OUTPUT.put_line (SQLERRM);
      END;

      l_attendance_id := '';
      l_object_version_number := '';
      error_desc := '';
      lv_est_flag := '';
      --COMMIT;
   END LOOP;

   CLOSE c_est;
--dbms_output.put_line('Location ID        : '||l_location_id);
EXCEPTION
   WHEN OTHERS
   THEN
      DBMS_OUTPUT.put_line (SQLERRM);
END;

/

For more details, visit

Entering Qualifications

I hope you like the post.

Please provide feedback for my improvement.

Leave a comment for any query.




2 comments:

  1. good info..I was searching n got it..i have not yet tried for my project..but look like details given will work out.
    Thanks buddy!!

    ReplyDelete
  2. for the occasion.One may usually offer a specific surprise on a specific year or use some of the ideas you are able to shock gift for employee leaving

    ReplyDelete