create or replace PROCEDURE HRIS_CREATE_USER_ACCOUNTS(
    P_PASSWORD HRIS_USERS.PASSWORD%TYPE := 'password@123')
AS
  V_USER_ID  NUMBER :=20;
  V_USERNAME VARCHAR2(255 BYTE);
      V_USERNAME := CONCAT(CONCAT(CONCAT(LOWER(TRIM(CUR_EMP.FIRST_NAME)),'_'),
      CASE
      WHEN CUR_EMP.MIDDLE_NAME IS NOT NULL THEN
        CONCAT(LOWER(TRIM(CUR_EMP.MIDDLE_NAME)), '_')
      ELSE
        ''
      END ),LOWER(TRIM(CUR_EMP.LAST_NAME)));
    END;
  END LOOP;
END;
