393: if p_applicant_number is NOT NULL then
394: begin
395: select person_id
396: into l_person_id
397: from per_people_f ppf
398: where ppf.applicant_number = p_applicant_number
399: and ppf.business_group_id +0 = p_business_group_id
400: and rownum = 1;
401:
435: -- 3652025 >>
436: if (p_applicant_number is NULL) then
437: begin
438: select applicant_number into p_applicant_number
439: from per_people_f
440: where person_id = p_person_id
441: and applicant_number is not null
442: and rownum = 1;
443: exception
530: if p_employee_number is NOT NULL then
531: begin
532: select person_id
533: into l_person_id
534: from per_people_f ppf
535: where ppf.employee_number = p_employee_number
536: and ppf.business_group_id +0 = p_business_group_id
537: and rownum = 1;
538:
662: if p_npw_number is NOT NULL then
663: begin
664: select person_id
665: into l_person_id
666: from per_people_f ppf
667: where ppf.npw_number = p_npw_number
668: and ppf.business_group_id +0 = p_business_group_id
669: and rownum = 1;
670:
1939: Cascades are all performed according to the locking ladder.
1940: NOTE
1941: P_FORM_CALL is set to 'Y' if this procedure is called from a forms
1942: module. In this case, the deletes are performed post-delete and a
1943: row therefore may not exist in per_people_f (for this person_id).
1944: For this reason the existance check will be ignored.
1945: */
1946: --
1947: PROCEDURE delete_a_person (p_person_id IN number,
2137: --
2138: -- Fix for bug 7045968 starts here
2139: -- Modified the select statement to use the person_type_id from
2140: -- per_person_type_usages_f
2141: -- rather than per_people_f
2142:
2143: /*select 'Y'
2144: into p_test_func
2145: from sys.dual
2144: into p_test_func
2145: from sys.dual
2146: where exists(
2147: select 'Future Person Type exists'
2148: from per_people_f ppf
2149: ,per_person_types ppt
2150: ,per_startup_person_types pst
2151: where ppf.person_type_id = ppt.person_type_id
2152: and ppf.person_id = p_person_id
2271:
2272:
2273: /*
2274: select 'Previous Person type exists'
2275: from per_people_f ppf
2276: ,per_person_types ppt
2277: ,per_startup_person_types pst
2278: where ppf.person_type_id = ppt.person_type_id
2279: and ppf.person_id = p_person_id