1: Package Body pqh_bre_ins as
2: /* $Header: pqbrerhi.pkb 115.6 2003/06/04 08:19:51 ggnanagu noship $ */
3: --
4: -- ----------------------------------------------------------------------------
5: -- | Private Global Definitions |
4: -- ----------------------------------------------------------------------------
5: -- | Private Global Definitions |
6: -- ----------------------------------------------------------------------------
7: --
8: g_package varchar2(33) := ' pqh_bre_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: pqh_bre_ins.g_reallocation_id_i := p_reallocation_id;
27: --
28: hr_utility.set_location(' Leaving:'||l_proc, 20);
29: End set_base_key_value;
30: --
187: Cursor C_Sel2 is
188: Select null
189: from pqh_bdgt_pool_realloctions
190: where reallocation_id =
191: pqh_bre_ins.g_reallocation_id_i;
192: --
193: l_proc varchar2(72) := g_package||'pre_insert';
194: l_exists varchar2(1);
195: --
195: --
196: Begin
197: hr_utility.set_location('Entering:'||l_proc, 5);
198: --
199: If (pqh_bre_ins.g_reallocation_id_i is not null) Then
200: --
201: -- Verify registered primary key values not already in use
202: --
203: Open C_Sel2;
215: --
216: -- Use registered key values and clear globals
217: --
218: p_rec.reallocation_id :=
219: pqh_bre_ins.g_reallocation_id_i;
220: pqh_bre_ins.g_reallocation_id_i := null;
221: Else
222: --
223: -- No registerd key values, so select the next sequence number
216: -- Use registered key values and clear globals
217: --
218: p_rec.reallocation_id :=
219: pqh_bre_ins.g_reallocation_id_i;
220: pqh_bre_ins.g_reallocation_id_i := null;
221: Else
222: --
223: -- No registerd key values, so select the next sequence number
224: --
343: hr_multi_message.end_validation_set;
344: --
345: -- Call the supporting pre-insert operation
346: --
347: pqh_bre_ins.pre_insert(p_rec);
348: --
349: -- Insert the row
350: --
351: pqh_bre_ins.insert_dml(p_rec);
347: pqh_bre_ins.pre_insert(p_rec);
348: --
349: -- Insert the row
350: --
351: pqh_bre_ins.insert_dml(p_rec);
352: --
353: -- Call the supporting post-insert operation
354: --
355: pqh_bre_ins.post_insert
351: pqh_bre_ins.insert_dml(p_rec);
352: --
353: -- Call the supporting post-insert operation
354: --
355: pqh_bre_ins.post_insert
356: (p_effective_date
357: ,p_rec
358: );
359: --
411: --
412: -- Having converted the arguments into the pqh_bre_rec
413: -- plsql record structure we call the corresponding record business process.
414: --
415: pqh_bre_ins.ins
416: (p_effective_date
417: ,l_rec
418: );
419: --
425: --
426: hr_utility.set_location(' Leaving:'||l_proc, 10);
427: End ins;
428: --
429: end pqh_bre_ins;