1: Package Body hr_int_ins as
2: /* $Header: hrintrhi.pkb 115.0 2004/01/09 01:40 vkarandi noship $ */
3: --
4: -- ----------------------------------------------------------------------------
5: -- | Private Global Definitions |
4: -- ----------------------------------------------------------------------------
5: -- | Private Global Definitions |
6: -- ----------------------------------------------------------------------------
7: --
8: g_package varchar2(33) := ' hr_int_ins.'; -- Global package name
9: --
10: -- The following global variables are only to be used by
11: -- the set_base_key_value and pre_insert procedures.
12: --
22: --
23: Begin
24: hr_utility.set_location('Entering:'||l_proc, 10);
25: --
26: hr_int_ins.g_integration_id_i := p_integration_id;
27: --
28: hr_utility.set_location(' Leaving:'||l_proc, 20);
29: End set_base_key_value;
30: --
241: Cursor C_Sel2 is
242: Select null
243: from hr_ki_integrations
244: where integration_id =
245: hr_int_ins.g_integration_id_i;
246: --
247: l_proc varchar2(72) := g_package||'pre_insert';
248: l_exists varchar2(1);
249: --
249: --
250: Begin
251: hr_utility.set_location('Entering:'||l_proc, 5);
252: --
253: If (hr_int_ins.g_integration_id_i is not null) Then
254: --
255: -- Verify registered primary key values not already in use
256: --
257: Open C_Sel2;
269: --
270: -- Use registered key values and clear globals
271: --
272: p_rec.integration_id :=
273: hr_int_ins.g_integration_id_i;
274: hr_int_ins.g_integration_id_i := null;
275: Else
276: --
277: -- No registerd key values, so select the next sequence number
270: -- Use registered key values and clear globals
271: --
272: p_rec.integration_id :=
273: hr_int_ins.g_integration_id_i;
274: hr_int_ins.g_integration_id_i := null;
275: Else
276: --
277: -- No registerd key values, so select the next sequence number
278: --
447: hr_multi_message.end_validation_set;
448: --
449: -- Call the supporting pre-insert operation
450: --
451: hr_int_ins.pre_insert(p_rec);
452: --
453: -- Insert the row
454: --
455: hr_int_ins.insert_dml(p_rec);
451: hr_int_ins.pre_insert(p_rec);
452: --
453: -- Insert the row
454: --
455: hr_int_ins.insert_dml(p_rec);
456: --
457: -- Call the supporting post-insert operation
458: --
459: hr_int_ins.post_insert
455: hr_int_ins.insert_dml(p_rec);
456: --
457: -- Call the supporting post-insert operation
458: --
459: hr_int_ins.post_insert
460: (p_rec
461: );
462: --
463: -- Call to raise any errors on multi-message list
566: --
567: -- Having converted the arguments into the hr_int_rec
568: -- plsql record structure we call the corresponding record business process.
569: --
570: hr_int_ins.ins
571: (l_rec
572: );
573: --
574: -- As the primary key argument(s)
579: --
580: hr_utility.set_location(' Leaving:'||l_proc, 10);
581: End ins;
582: --
583: end hr_int_ins;