ORA-20001: System Error: Procedure sort_segment_order at Step 40

ORA-20001: System Error: Procedure sort_segment_order at Step 40

DECLARE
    lc_employee_number            per_all_people_f.employee_number%TYPE; -- := 'tan_01';
    ln_person_id                  per_all_people_f.person_id%TYPE;
    ln_assignment_id              per_all_assignments_f.assignment_id%TYPE;
    ln_object_ver_number          per_all_assignments_f.object_version_number%TYPE;
    ln_address_id                 PER_ADDRESSES.ADDRESS_ID%TYPE;
    ln_asg_ovn                    NUMBER;


    ld_per_effective_start_date   per_all_people_f.effective_start_date%TYPE;
    ld_per_effective_end_date     per_all_people_f.effective_end_date%TYPE;
    lc_full_name                  per_all_people_f.full_name%TYPE;
    ln_per_comment_id             per_all_people_f.comment_id%TYPE;
    ln_assignment_sequence        per_all_assignments_f.assignment_sequence%TYPE;
    lc_assignment_number          per_all_assignments_f.assignment_number%TYPE;


    lb_name_combination_warning   BOOLEAN;
    lb_assign_payroll_warning     BOOLEAN;
    lb_orig_hire_warning          BOOLEAN;
   
    -------------------
    ------------Assignment


    l_assignment_id            NUMBER;
    l_effective_date           DATE := NULL;
    l_supervisor_id            NUMBER;
    lb_correction              BOOLEAN;
    lb_update                  BOOLEAN;
    lb_update_override         BOOLEAN;
    lb_update_change_insert    BOOLEAN;
    lc_dt_ud_mode              VARCHAR2 (100) := NULL;
    l_obj_version_num          NUMBER;
    l_organization_id          NUMBER := 81;
    l_soft_coding_keyflex_id   hr_soft_coding_keyflex.soft_coding_keyflex_id%TYPE;
    l_concatenated_segments    VARCHAR2 (2000);
    l_comment_id               per_all_assignments_f.comment_id%TYPE;
    l_effective_start_date     per_all_assignments_f.effective_start_date%TYPE;
    l_effective_end_date       per_all_assignments_f.effective_end_date%TYPE;
    l_no_managers_warning      BOOLEAN;
    l_other_manager_warning    BOOLEAN;
    error_message              VARCHAR2 (4000) := NULL;
    current_records            NUMBER;
    total_records              NUMBER;
    error_records              NUMBER;
    l_effective_date_valid     NUMBER;
    error_message1             VARCHAR2 (4000) := NULL;  
   
    v_ledger_id              gl_ledgers.ledger_id%type;
    v_job_definition_id      PER_JOB_DEFINITIONS.job_definition_id%type;
    v_position_definition_id per_position_definitions.position_definition_id%type;   
    v_location_id            hr_locations_all.location_id%type;
    v_emp_count              number := 0;
-- Out Variables for Update Employee Assgment Criteria
-- -------------------------------------------------------------------------------
-- ln_people_group_id  NUMBER                     := null;   -- This will cause error  ORA-20001: System Error: Procedure  at Step 40
ln_people_group_id   NUMBER                      := hr_api.g_number;   --  PEOPLE_GROUP_ID
  end;


ln_special_ceiling_step_id                          PER_ALL_ASSIGNMENTS_F.SPECIAL_CEILING_STEP_ID%TYPE;
lc_group_name                                       VARCHAR2(30);
ld_effective_start_date                             PER_ALL_ASSIGNMENTS_F.EFFECTIVE_START_DATE%TYPE;
ld_effective_end_date                               PER_ALL_ASSIGNMENTS_F.EFFECTIVE_END_DATE%TYPE;
lb_org_now_no_manager_warning                       BOOLEAN;
lb_other_manager_warning                            BOOLEAN;
lb_spp_delete_warning                               BOOLEAN;
lc_entries_changed_warning                          VARCHAR2(30);




Entering: HR_ASSIGNMENT_BK3.UPDATE_EMP_ASG_CRITERIA_B                   10
  hr_api.validate_commit_unit                                           10
Leaving: HR_ASSIGNMENT_BK3.UPDATE_EMP_ASG_CRITERIA_B                   20
Entering hr_kflex_utility set_profiles                                  5
hr_kflex_utility set_profiles                                           10
hr_kflex_utility set_profiles                                           20
hr_kflex_utility set_profiles                                           30
hr_kflex_utility set_profiles                                           40
hr_kflex_utility set_profiles                                           50
Leaving hr_kflex_utility set_profiles                                   100
Entering hr_kflex_utility set_session_date                              5
hr_kflex_utility set_session_date                                       30
Leaving hr_kflex_utility set_session_date                               100
Entering:upd_or_sel_keyflex_comb                                        10
upd_or_sel_keyflex_comb                                                 20
Entering:check_ignore_varray                                            10
Seg3 $Sys_Def$                                                         101
Entering:ins_or_sel_keyflex_comb                                        10
ins_or_sel_keyflex_comb                                                 20
Entering:check_ignore_varray                                            10
ins_or_sel_keyflex_comb                                                 30
Entering:sort_segment_order                                             10
sort_segment_order                                                      20
sort_segment_order                                                      30
sort_segment_order                                                      40
ins_or_sel_keyflex_comb                                                 100
Leaving upd_or_sel_keyflex_comb                                         140
-----RollBack ORA-20001: System Error: Procedure sort_segment_order at Step 40
Cause:        The procedure sort_segment_order has created an error at Step 40. 
Action:        Contact your system administrator quoting the procedure sort_segment_order and Step 40.

i found the solution which is to add at least one value to the key flexfield : " People Group Flexfield" .
Regards,
flex.PNGflex2.PNG

No comments

2015@Bahaa Barghouti. Powered by Blogger.