126: --
127: -- If the datetrack_mode is not INSERT then we must populate the WHO
128: -- columns with the 'old' creation values and 'new' updated values.
129: --
130: If (p_datetrack_mode <> hr_api.g_insert) then
131: hr_utility.set_location(l_proc, 10);
132: --
133: -- Get the object version number for the insert
134: --
233: --
234: hr_utility.set_location(' Leaving:'||l_proc, 15);
235: --
236: Exception
237: When hr_api.check_integrity_violated Then
238: -- A check constraint has been violated
239: --
240: ame_cnu_shd.constraint_error
241: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
237: When hr_api.check_integrity_violated Then
238: -- A check constraint has been violated
239: --
240: ame_cnu_shd.constraint_error
241: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
242: When hr_api.unique_integrity_violated Then
243: -- Unique integrity has been violated
244: --
245: ame_cnu_shd.constraint_error
238: -- A check constraint has been violated
239: --
240: ame_cnu_shd.constraint_error
241: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
242: When hr_api.unique_integrity_violated Then
243: -- Unique integrity has been violated
244: --
245: ame_cnu_shd.constraint_error
246: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
242: When hr_api.unique_integrity_violated Then
243: -- Unique integrity has been violated
244: --
245: ame_cnu_shd.constraint_error
246: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
247: When Others Then
248: --
249: Raise;
250: End dt_insert_dml;
444: );
445: --
446: exception
447: --
448: when hr_api.cannot_find_prog_unit then
449: --
450: hr_api.cannot_find_prog_unit_error
451: (p_module_name => 'AME_CONDITION_USAGES'
452: ,p_hook_type => 'AI');
446: exception
447: --
448: when hr_api.cannot_find_prog_unit then
449: --
450: hr_api.cannot_find_prog_unit_error
451: (p_module_name => 'AME_CONDITION_USAGES'
452: ,p_hook_type => 'AI');
453: --
454: end;
479: --
480: -- Post Failure:
481: -- The Lck process can fail for:
482: -- 1) When attempting to lock the row the row could already be locked by
483: -- another user. This will raise the HR_Api.Object_Locked exception.
484: -- 2) When attempting to the lock the parent which doesn't exist.
485: -- For the entity to be locked the parent must exist!
486: --
487: -- Developer Implementation Notes:
559: ,p_rec in out nocopy ame_cnu_shd.g_rec_type
560: ) is
561: --
562: l_proc varchar2(72) := g_package||'ins';
563: l_datetrack_mode varchar2(30) := hr_api.g_insert;
564: l_validation_start_date date;
565: l_validation_end_date date;
566: --
567: Begin