69: and l_date_from between per.effective_start_date
70: and per.effective_end_date;
71: --
72: begin
73: hr_utility.set_location('Entering:'|| l_proc, 5);
74: --
75: -- Issue a savepoint if operating in validation only mode.
76: --
77: if p_validate then
90: (p_api_name => l_proc,
91: p_argument => 'date_from',
92: p_argument_value => p_date_from);
93: --
94: hr_utility.set_location(l_proc, 6);
95: --
96: l_date_from := trunc(p_date_from);
97: --
98: -- Get business_group_id using person_id.
102: into l_business_group_id;
103: --
104: if csr_bus_grp%notfound then
105: close csr_bus_grp;
106: hr_utility.set_message(801, 'HR_7298_ADD_PERSON_INVALID');
107: hr_utility.raise_error;
108: end if;
109: --
110: close csr_bus_grp;
103: --
104: if csr_bus_grp%notfound then
105: close csr_bus_grp;
106: hr_utility.set_message(801, 'HR_7298_ADD_PERSON_INVALID');
107: hr_utility.raise_error;
108: end if;
109: --
110: close csr_bus_grp;
111: --
108: end if;
109: --
110: close csr_bus_grp;
111: --
112: hr_utility.set_location(l_proc, 7);
113: --
114: -- Insert Person Address details.
115: --
116: per_kad_ins.ins
160: ,p_validate => FALSE
161: ,p_effective_date => p_effective_date
162: );
163: --
164: hr_utility.set_location(l_proc, 8);
165: --
166: -- When in validation only mode raise the Validate_Enabled exception
167: --
168: if p_validate then
168: if p_validate then
169: raise hr_api.validate_enabled;
170: end if;
171: --
172: hr_utility.set_location(' Leaving:'||l_proc, 11);
173: exception
174: when hr_api.validate_enabled then
175: --
176: -- As the Validate_Enabled exception has been raised
236: --
237: l_proc varchar2(72) := g_package||'create_gb_person_address';
238: --
239: begin
240: hr_utility.set_location('Entering:'|| l_proc, 5);
241: --
242: -- Create Person Address details.
243: --
244: hr_kiosk_address_api.create_person_address
283: ,p_address_id => p_address_id
284: ,p_object_version_number => p_object_version_number
285: );
286: --
287: hr_utility.set_location(' Leaving:'||l_proc, 10);
288: end create_gb_person_address;
289: --
290: -- ----------------------------------------------------------------------------
291: -- |-----------------------< create_us_person_address >-----------------------|
339: --
340: l_proc varchar2(72) := g_package||'create_us_person_address';
341: --
342: begin
343: hr_utility.set_location('Entering:'|| l_proc, 5);
344: --
345: -- Create Person Address details.
346: --
347: hr_kiosk_address_api.create_person_address
388: ,p_address_id => p_address_id
389: ,p_object_version_number => p_object_version_number
390: );
391: --
392: hr_utility.set_location(' Leaving:'||l_proc, 10);
393: end create_us_person_address;
394: --
395: -- ----------------------------------------------------------------------------
396: -- |------------------------< update_person_address >-------------------------|
445: l_object_version_number per_addresses.object_version_number%TYPE;
446: l_proc varchar2(72) := g_package||'update_person_address';
447: --
448: begin
449: hr_utility.set_location('Entering:'|| l_proc, 5);
450: --
451: -- Issue a savepoint if operating in validation only mode.
452: --
453: if p_validate then
452: --
453: if p_validate then
454: savepoint update_person_address;
455: end if;
456: hr_utility.set_location(l_proc, 6);
457: --
458: l_object_version_number := p_object_version_number;
459: --
460: -- Update Person Address details.
502: ,p_validate => FALSE
503: ,p_effective_date => p_effective_date
504: );
505: --
506: hr_utility.set_location(l_proc, 8);
507: --
508: -- When in validation only mode raise the Validate_Enabled exception
509: --
510: if p_validate then
510: if p_validate then
511: raise hr_api.validate_enabled;
512: end if;
513: --
514: hr_utility.set_location(' Leaving:'||l_proc, 11);
515: exception
516: when hr_api.validate_enabled then
517: --
518: -- As the Validate_Enabled exception has been raised
581: from per_addresses addr
582: where addr.address_id = p_address_id;
583: --
584: begin
585: hr_utility.set_location('Entering:'|| l_proc, 5);
586: --
587: -- Check that the Address identified is GB style.
588: --
589: open csr_add_style;
592: if csr_add_style%notfound then
593: --
594: close csr_add_style;
595: --
596: hr_utility.set_location(l_proc, 7);
597: --
598: hr_utility.set_message(801, 'HR_7220_INVALID_PRIMARY_KEY');
599: hr_utility.raise_error;
600: --
594: close csr_add_style;
595: --
596: hr_utility.set_location(l_proc, 7);
597: --
598: hr_utility.set_message(801, 'HR_7220_INVALID_PRIMARY_KEY');
599: hr_utility.raise_error;
600: --
601: else
602: --
595: --
596: hr_utility.set_location(l_proc, 7);
597: --
598: hr_utility.set_message(801, 'HR_7220_INVALID_PRIMARY_KEY');
599: hr_utility.raise_error;
600: --
601: else
602: --
603: close csr_add_style;
603: close csr_add_style;
604: --
605: if l_style <> 'GB' then
606: --
607: hr_utility.set_location(l_proc, 8);
608: --
609: hr_utility.set_message(801, 'HR_7788_ADD_INV_NOT_GB_STYLE');
610: hr_utility.raise_error;
611: --
605: if l_style <> 'GB' then
606: --
607: hr_utility.set_location(l_proc, 8);
608: --
609: hr_utility.set_message(801, 'HR_7788_ADD_INV_NOT_GB_STYLE');
610: hr_utility.raise_error;
611: --
612: end if;
613: end if;
606: --
607: hr_utility.set_location(l_proc, 8);
608: --
609: hr_utility.set_message(801, 'HR_7788_ADD_INV_NOT_GB_STYLE');
610: hr_utility.raise_error;
611: --
612: end if;
613: end if;
614: --
611: --
612: end if;
613: end if;
614: --
615: hr_utility.set_location(l_proc, 9);
616: --
617: -- Update Person Address details.
618: --
619: hr_kiosk_address_api.update_person_address
655: ,p_addr_attribute19 => p_addr_attribute19
656: ,p_addr_attribute20 => p_addr_attribute20
657: );
658: --
659: hr_utility.set_location(' Leaving:'||l_proc, 11);
660: end update_gb_person_address;
661: --
662: -- ----------------------------------------------------------------------------
663: -- |-----------------------< update_us_person_address >-----------------------|
715: from per_addresses
716: where address_id = p_address_id;
717: --
718: begin
719: hr_utility.set_location('Entering:'|| l_proc, 5);
720: --
721: -- Check that the address is US style.
722: --
723: open csr_add_style;
725: into l_style;
726: if csr_add_style%notfound then
727: close csr_add_style;
728: --
729: hr_utility.set_message(801, 'HR_7220_INVALID_PRIMARY_KEY');
730: hr_utility.raise_error;
731: else
732: hr_utility.set_location(l_proc, 10);
733: --
726: if csr_add_style%notfound then
727: close csr_add_style;
728: --
729: hr_utility.set_message(801, 'HR_7220_INVALID_PRIMARY_KEY');
730: hr_utility.raise_error;
731: else
732: hr_utility.set_location(l_proc, 10);
733: --
734: close csr_add_style;
728: --
729: hr_utility.set_message(801, 'HR_7220_INVALID_PRIMARY_KEY');
730: hr_utility.raise_error;
731: else
732: hr_utility.set_location(l_proc, 10);
733: --
734: close csr_add_style;
735: --
736: if l_style <> 'US' then
733: --
734: close csr_add_style;
735: --
736: if l_style <> 'US' then
737: hr_utility.set_message(801, 'HR_51283_ADD_MUST_BE_US_STYLE');
738: hr_utility.raise_error;
739: end if;
740: end if;
741: --
734: close csr_add_style;
735: --
736: if l_style <> 'US' then
737: hr_utility.set_message(801, 'HR_51283_ADD_MUST_BE_US_STYLE');
738: hr_utility.raise_error;
739: end if;
740: end if;
741: --
742: hr_utility.set_location(l_proc, 15);
738: hr_utility.raise_error;
739: end if;
740: end if;
741: --
742: hr_utility.set_location(l_proc, 15);
743: --
744: -- Update Person Address details.
745: --
746: hr_kiosk_address_api.update_person_address
784: ,p_addr_attribute19 => p_addr_attribute19
785: ,p_addr_attribute20 => p_addr_attribute20
786: );
787: --
788: hr_utility.set_location(' Leaving:'||l_proc, 20);
789: end update_us_person_address;
790: --
791: end hr_kiosk_address_api;