28: cursor csr_sec_grp is
29: select pbg.security_group_id,
30: pbg.legislation_code
31: from per_business_groups_perf pbg
32: , per_allocated_checklists pac
33: , per_all_people_f paf
34: where pac.allocated_checklist_id = p_allocated_checklist_id
35: and pac.person_id = paf.person_id
36: and trunc(sysdate) between paf.EFFECTIVE_START_DATE
102: --
103: cursor csr_leg_code is
104: select pbg.legislation_code
105: from per_business_groups_perf pbg
106: , per_allocated_checklists pac
107: -- , EDIT_HERE table_name(s) 333
108: , per_all_people_f paf
109: where pac.allocated_checklist_id = p_allocated_checklist_id
110: and pac.person_id = paf.person_id
172: -- |--------------------------< chk_name_unq >--------------------------------|
173: -- ----------------------------------------------------------------------------
174: --
175: PROCEDURE chk_name_unq
176: (p_checklist_name IN per_allocated_checklists.checklist_name%TYPE
177: ,p_checklist_category IN per_allocated_checklists.checklist_category%TYPE
178: ,p_allocated_checklist_id IN per_allocated_checklists.allocated_checklist_id%TYPE
179: ,p_person_id IN per_allocated_checklists.person_id%TYPE
180: ,p_object_version_number IN per_allocated_checklists.object_version_number%TYPE
173: -- ----------------------------------------------------------------------------
174: --
175: PROCEDURE chk_name_unq
176: (p_checklist_name IN per_allocated_checklists.checklist_name%TYPE
177: ,p_checklist_category IN per_allocated_checklists.checklist_category%TYPE
178: ,p_allocated_checklist_id IN per_allocated_checklists.allocated_checklist_id%TYPE
179: ,p_person_id IN per_allocated_checklists.person_id%TYPE
180: ,p_object_version_number IN per_allocated_checklists.object_version_number%TYPE
181: ) IS
174: --
175: PROCEDURE chk_name_unq
176: (p_checklist_name IN per_allocated_checklists.checklist_name%TYPE
177: ,p_checklist_category IN per_allocated_checklists.checklist_category%TYPE
178: ,p_allocated_checklist_id IN per_allocated_checklists.allocated_checklist_id%TYPE
179: ,p_person_id IN per_allocated_checklists.person_id%TYPE
180: ,p_object_version_number IN per_allocated_checklists.object_version_number%TYPE
181: ) IS
182: --
175: PROCEDURE chk_name_unq
176: (p_checklist_name IN per_allocated_checklists.checklist_name%TYPE
177: ,p_checklist_category IN per_allocated_checklists.checklist_category%TYPE
178: ,p_allocated_checklist_id IN per_allocated_checklists.allocated_checklist_id%TYPE
179: ,p_person_id IN per_allocated_checklists.person_id%TYPE
180: ,p_object_version_number IN per_allocated_checklists.object_version_number%TYPE
181: ) IS
182: --
183: -- Declare cursor to check name is unique.
176: (p_checklist_name IN per_allocated_checklists.checklist_name%TYPE
177: ,p_checklist_category IN per_allocated_checklists.checklist_category%TYPE
178: ,p_allocated_checklist_id IN per_allocated_checklists.allocated_checklist_id%TYPE
179: ,p_person_id IN per_allocated_checklists.person_id%TYPE
180: ,p_object_version_number IN per_allocated_checklists.object_version_number%TYPE
181: ) IS
182: --
183: -- Declare cursor to check name is unique.
184: --
183: -- Declare cursor to check name is unique.
184: --
185: CURSOR csr_unique_name IS
186: SELECT 'x'
187: FROM per_allocated_checklists
188: WHERE checklist_name = p_checklist_name
189: AND checklist_category = p_checklist_category
190: AND person_id = p_person_id
191: AND allocated_checklist_id <> nvl(p_allocated_checklist_id,-1);
246: --
247: EXCEPTION
248: WHEN app_exception.application_exception THEN
249: IF hr_multi_message.exception_add
250: (p_associated_column1 => 'PER_ALLOCATED_CHECKLISTS.CHECKLIST_NAME'
251: ) THEN
252: hr_utility.set_location(' Leaving:'|| l_proc, 40);
253: RAISE;
254: END IF;