DBA Data[Home] [Help]

APPS.PER_INC_BUS dependencies on PER_US_OSHA_NUMBERS

Line 790: FROM per_us_osha_numbers

786: -- Declare cursor
787: --
788: cursor csr_num(p_year number,p_bg_id number) is
789: SELECT next_value
790: FROM per_us_osha_numbers
791: WHERE case_year = p_year
792: AND business_group_id = p_bg_id
793: FOR UPDATE OF next_value NOWAIT;
794: --

Line 798: l_next_num per_us_osha_numbers.next_value%type;

794: --
795: -- Declare local variables
796: --
797: l_case_num per_work_incidents.incident_reference%type;
798: l_next_num per_us_osha_numbers.next_value%type;
799: p_year number;
800: l_proc varchar2(72) := g_package||'get_osha_case_number';
801: --
802: Begin

Line 823: UPDATE per_us_osha_numbers

819: fnd_message.raise_error;
820: --
821: else
822: --
823: UPDATE per_us_osha_numbers
824: SET next_value = next_value+1
825: WHERE CURRENT OF csr_num;
826: --
827: close csr_num;

Line 3126: --PER_US_OSHA_NUMBERS table.

3122: Procedure create_osha_numbers(p_number_of_workers in number default 1,
3123: p_current_worker in number default 1) is
3124: --
3125: --cursor selects all US business groups, which are not yet have rows in
3126: --PER_US_OSHA_NUMBERS table.
3127: --
3128: cursor csr_us_bg is
3129: select business_group_id
3130: from hr_all_organization_units units

Line 3137: and not exists (select null from per_us_osha_numbers osha

3133: --and units.type = 'BG'
3134: and mod(business_group_id,p_number_of_workers) = p_current_worker-1
3135: and org.org_information_context = 'Business Group Information'
3136: and org.org_information9 = 'US'
3137: and not exists (select null from per_us_osha_numbers osha
3138: where osha.business_group_id = units.business_group_id
3139: and osha.case_year = 1900
3140: );
3141:

Line 3159: insert into per_us_osha_numbers(

3155: --
3156: -- Changed to 2200 for now
3157: --
3158: for x in 1900 .. 2200 loop
3159: insert into per_us_osha_numbers(
3160: case_year,
3161: business_group_id,
3162: next_value,
3163: last_update_date,