139: FROM per_business_groups pbg
140: WHERE pbg.business_group_id = p_business_group_id;
141: --
142: BEGIN
143: hr_utility.set_location('Entering:'|| l_proc, 10);
144: --
145: -- Validation IN addition to Row Handlers
146: --
147: -- Check that the specified business group is valid.
150: FETCH csr_bg
151: INTO l_legislation_code;
152: IF csr_bg%notfound THEN
153: CLOSE csr_bg;
154: hr_utility.set_message(801, 'HR_7208_API_BUS_GRP_INVALID');
155: hr_utility.raise_error;
156: END IF;
157: CLOSE csr_bg;
158: hr_utility.set_location(l_proc, 20);
151: INTO l_legislation_code;
152: IF csr_bg%notfound THEN
153: CLOSE csr_bg;
154: hr_utility.set_message(801, 'HR_7208_API_BUS_GRP_INVALID');
155: hr_utility.raise_error;
156: END IF;
157: CLOSE csr_bg;
158: hr_utility.set_location(l_proc, 20);
159: --
154: hr_utility.set_message(801, 'HR_7208_API_BUS_GRP_INVALID');
155: hr_utility.raise_error;
156: END IF;
157: CLOSE csr_bg;
158: hr_utility.set_location(l_proc, 20);
159: --
160: -- Check that the legislation of the specified business group is 'AE'.
161: --
162: IF l_legislation_code <> 'AE' THEN
159: --
160: -- Check that the legislation of the specified business group is 'AE'.
161: --
162: IF l_legislation_code <> 'AE' THEN
163: hr_utility.set_message(801, 'HR_7961_PER_BUS_GRP_INVALID');
164: hr_utility.set_message_token('LEG_CODE','AE');
165: hr_utility.raise_error;
166: END IF;
167: hr_utility.set_location(l_proc, 30);
160: -- Check that the legislation of the specified business group is 'AE'.
161: --
162: IF l_legislation_code <> 'AE' THEN
163: hr_utility.set_message(801, 'HR_7961_PER_BUS_GRP_INVALID');
164: hr_utility.set_message_token('LEG_CODE','AE');
165: hr_utility.raise_error;
166: END IF;
167: hr_utility.set_location(l_proc, 30);
168: --
161: --
162: IF l_legislation_code <> 'AE' THEN
163: hr_utility.set_message(801, 'HR_7961_PER_BUS_GRP_INVALID');
164: hr_utility.set_message_token('LEG_CODE','AE');
165: hr_utility.raise_error;
166: END IF;
167: hr_utility.set_location(l_proc, 30);
168: --
169: -- Call the person business process
163: hr_utility.set_message(801, 'HR_7961_PER_BUS_GRP_INVALID');
164: hr_utility.set_message_token('LEG_CODE','AE');
165: hr_utility.raise_error;
166: END IF;
167: hr_utility.set_location(l_proc, 30);
168: --
169: -- Call the person business process
170: --
171: hr_employee_api.create_employee
291: ,p_name_combination_warning => p_name_combination_warning
292: ,p_assign_payroll_warning => p_assign_payroll_warning
293: ,p_orig_hire_warning => p_orig_hire_warning);
294: --
295: hr_utility.set_location(' Leaving:'||l_proc, 40);
296: --
297: end create_ae_employee;
298: end hr_ae_employee_api;