118: Begin
119: --
120: hr_utility.set_location('Entering:'||l_proc, 5);
121: --
122: l_api_updating := ben_act_shd.api_updating
123: (p_person_action_id => p_person_action_id,
124: p_object_version_number => p_object_version_number);
125: --
126: if (l_api_updating
124: p_object_version_number => p_object_version_number);
125: --
126: if (l_api_updating
127: and nvl(p_person_action_id,hr_api.g_number)
128: <> ben_act_shd.g_old_rec.person_action_id) then
129: --
130: -- raise error as PK has changed
131: --
132: ben_act_shd.constraint_error('BEN_PERSON_ACTIONS_PK');
128: <> ben_act_shd.g_old_rec.person_action_id) then
129: --
130: -- raise error as PK has changed
131: --
132: ben_act_shd.constraint_error('BEN_PERSON_ACTIONS_PK');
133: --
134: elsif not l_api_updating then
135: --
136: -- check if PK is null
138: if p_person_action_id is not null then
139: --
140: -- raise error as PK is not null
141: --
142: ben_act_shd.constraint_error('BEN_PERSON_ACTIONS_PK');
143: --
144: end if;
145: --
146: end if;
190: Begin
191: --
192: hr_utility.set_location('Entering:'||l_proc,5);
193: --
194: l_api_updating := ben_act_shd.api_updating
195: (p_person_action_id => p_person_action_id,
196: p_object_version_number => p_object_version_number);
197: --
198: if (l_api_updating
196: p_object_version_number => p_object_version_number);
197: --
198: if (l_api_updating
199: and nvl(p_benefit_action_id,hr_api.g_number)
200: <> nvl(ben_act_shd.g_old_rec.benefit_action_id,hr_api.g_number)
201: or not l_api_updating) then
202: --
203: -- check if benefit_action_id value exists in ben_benefit_actions table
204: --
211: --
212: -- raise error as FK does not relate to PK in ben_benefit_actions
213: -- table.
214: --
215: ben_act_shd.constraint_error('BEN_PERSON_ACTIONS_FK1');
216: --
217: end if;
218: --
219: close c1;
261: Begin
262: --
263: hr_utility.set_location('Entering:'||l_proc, 5);
264: --
265: l_api_updating := ben_act_shd.api_updating
266: (p_person_action_id => p_person_action_id,
267: p_object_version_number => p_object_version_number);
268: --
269: if (l_api_updating
267: p_object_version_number => p_object_version_number);
268: --
269: if (l_api_updating
270: and p_action_status_cd
271: <> nvl(ben_act_shd.g_old_rec.action_status_cd,hr_api.g_varchar2)
272: or not l_api_updating) then
273: --
274: -- check if value of lookup falls within lookup type.
275: --
296: --
297: -- ----------------------------------------------------------------------------
298: -- |---------------------------< insert_validate >----------------------------|
299: -- ----------------------------------------------------------------------------
300: Procedure insert_validate(p_rec in ben_act_shd.g_rec_type
301: ,p_effective_date in date) is
302: --
303: l_proc varchar2(72) := g_package||'insert_validate';
304: --
329: --
330: -- ----------------------------------------------------------------------------
331: -- |---------------------------< update_validate >----------------------------|
332: -- ----------------------------------------------------------------------------
333: Procedure update_validate(p_rec in ben_act_shd.g_rec_type
334: ,p_effective_date in date) is
335: --
336: l_proc varchar2(72) := g_package||'update_validate';
337: --
362: --
363: -- ----------------------------------------------------------------------------
364: -- |---------------------------< delete_validate >----------------------------|
365: -- ----------------------------------------------------------------------------
366: Procedure delete_validate(p_rec in ben_act_shd.g_rec_type
367: ,p_effective_date in date) is
368: --
369: l_proc varchar2(72) := g_package||'delete_validate';
370: --