DBA Data[Home] [Help]

PACKAGE BODY: APPS.BEN_POE_RT_API

Source


1 Package Body ben_POE_RT_api as
2 /* $Header: beprtapi.pkb 115.4 2002/12/16 17:39:50 glingapp ship $ */
3 --
4 -- Package Variables
5 --
6 g_package  varchar2(33) := '  ben_POE_RT_api.';
7 --
8 -- ----------------------------------------------------------------------------
9 -- |------------------------< create_POE_RT >----------------------|
10 -- ----------------------------------------------------------------------------
11 --
12 procedure create_POE_RT
13   (p_validate                       in  boolean   default false
14   ,p_poe_rt_id                      out nocopy number
15   ,p_effective_start_date           out nocopy date
16   ,p_effective_end_date             out nocopy date
17   ,p_mn_poe_num                     in  number    default null
18   ,p_mx_poe_num                     in  number    default null
19   ,p_no_mn_poe_flag                 in  varchar2  default 'N'
20   ,p_no_mx_poe_flag                 in  varchar2  default 'N'
21   ,p_rndg_cd                        in  varchar2  default null
22   ,p_rndg_rl                        in  number    default null
23   ,p_poe_nnmntry_uom                in  varchar2  default null
24   ,p_vrbl_rt_prfl_id                in  number    default null
25   ,p_business_group_id              in  number    default null
26   ,p_prt_attribute_category         in  varchar2  default null
27   ,p_prt_attribute1                 in  varchar2  default null
28   ,p_prt_attribute2                 in  varchar2  default null
29   ,p_prt_attribute3                 in  varchar2  default null
30   ,p_prt_attribute4                 in  varchar2  default null
31   ,p_prt_attribute5                 in  varchar2  default null
32   ,p_prt_attribute6                 in  varchar2  default null
33   ,p_prt_attribute7                 in  varchar2  default null
34   ,p_prt_attribute8                 in  varchar2  default null
35   ,p_prt_attribute9                 in  varchar2  default null
36   ,p_prt_attribute10                in  varchar2  default null
37   ,p_prt_attribute11                in  varchar2  default null
38   ,p_prt_attribute12                in  varchar2  default null
39   ,p_prt_attribute13                in  varchar2  default null
40   ,p_prt_attribute14                in  varchar2  default null
41   ,p_prt_attribute15                in  varchar2  default null
42   ,p_prt_attribute16                in  varchar2  default null
43   ,p_prt_attribute17                in  varchar2  default null
44   ,p_prt_attribute18                in  varchar2  default null
45   ,p_prt_attribute19                in  varchar2  default null
46   ,p_prt_attribute20                in  varchar2  default null
47   ,p_prt_attribute21                in  varchar2  default null
48   ,p_prt_attribute22                in  varchar2  default null
49   ,p_prt_attribute23                in  varchar2  default null
50   ,p_prt_attribute24                in  varchar2  default null
51   ,p_prt_attribute25                in  varchar2  default null
52   ,p_prt_attribute26                in  varchar2  default null
53   ,p_prt_attribute27                in  varchar2  default null
54   ,p_prt_attribute28                in  varchar2  default null
55   ,p_prt_attribute29                in  varchar2  default null
56   ,p_prt_attribute30                in  varchar2  default null
57   ,p_object_version_number          out nocopy number
58   ,p_cbr_dsblty_apls_flag           in  varchar2  default 'N'
59   ,p_effective_date                 in  date
60   ) is
61   --
62   -- Declare cursors and local variables
63   --
64   l_poe_rt_id ben_poe_rt_f.poe_rt_id%TYPE;
65   l_effective_start_date ben_poe_rt_f.effective_start_date%TYPE;
66   l_effective_end_date ben_poe_rt_f.effective_end_date%TYPE;
67   l_proc varchar2(72) := g_package||'create_POE_RT';
68   l_object_version_number ben_poe_rt_f.object_version_number%TYPE;
69   --
70 begin
71   --
72   hr_utility.set_location('Entering:'|| l_proc, 10);
73   --
74   -- Issue a savepoint if operating in validation only mode
75   --
76   savepoint create_POE_RT;
77   --
78   hr_utility.set_location(l_proc, 20);
79   --
80   -- Process Logic
81   --
82   begin
83     --
84     -- Start of API User Hook for the before hook of create_POE_RT
85     --
86     ben_POE_RT_bk1.create_POE_RT_b
87       (
88        p_mn_poe_num                     =>  p_mn_poe_num
89       ,p_mx_poe_num                     =>  p_mx_poe_num
90       ,p_no_mn_poe_flag                 =>  p_no_mn_poe_flag
91       ,p_no_mx_poe_flag                 =>  p_no_mx_poe_flag
92       ,p_rndg_cd                        =>  p_rndg_cd
93       ,p_rndg_rl                        =>  p_rndg_rl
94       ,p_poe_nnmntry_uom                =>  p_poe_nnmntry_uom
95       ,p_vrbl_rt_prfl_id                =>  p_vrbl_rt_prfl_id
96       ,p_business_group_id              =>  p_business_group_id
97       ,p_prt_attribute_category         =>  p_prt_attribute_category
98       ,p_prt_attribute1                 =>  p_prt_attribute1
99       ,p_prt_attribute2                 =>  p_prt_attribute2
100       ,p_prt_attribute3                 =>  p_prt_attribute3
101       ,p_prt_attribute4                 =>  p_prt_attribute4
102       ,p_prt_attribute5                 =>  p_prt_attribute5
103       ,p_prt_attribute6                 =>  p_prt_attribute6
104       ,p_prt_attribute7                 =>  p_prt_attribute7
105       ,p_prt_attribute8                 =>  p_prt_attribute8
106       ,p_prt_attribute9                 =>  p_prt_attribute9
107       ,p_prt_attribute10                =>  p_prt_attribute10
108       ,p_prt_attribute11                =>  p_prt_attribute11
109       ,p_prt_attribute12                =>  p_prt_attribute12
110       ,p_prt_attribute13                =>  p_prt_attribute13
111       ,p_prt_attribute14                =>  p_prt_attribute14
112       ,p_prt_attribute15                =>  p_prt_attribute15
113       ,p_prt_attribute16                =>  p_prt_attribute16
114       ,p_prt_attribute17                =>  p_prt_attribute17
115       ,p_prt_attribute18                =>  p_prt_attribute18
116       ,p_prt_attribute19                =>  p_prt_attribute19
117       ,p_prt_attribute20                =>  p_prt_attribute20
118       ,p_prt_attribute21                =>  p_prt_attribute21
119       ,p_prt_attribute22                =>  p_prt_attribute22
120       ,p_prt_attribute23                =>  p_prt_attribute23
121       ,p_prt_attribute24                =>  p_prt_attribute24
122       ,p_prt_attribute25                =>  p_prt_attribute25
123       ,p_prt_attribute26                =>  p_prt_attribute26
124       ,p_prt_attribute27                =>  p_prt_attribute27
125       ,p_prt_attribute28                =>  p_prt_attribute28
126       ,p_prt_attribute29                =>  p_prt_attribute29
127       ,p_prt_attribute30                =>  p_prt_attribute30
128       ,p_cbr_dsblty_apls_flag           =>  p_cbr_dsblty_apls_flag
129       ,p_effective_date                 => trunc(p_effective_date)
130       );
131   exception
132     when hr_api.cannot_find_prog_unit then
133       hr_api.cannot_find_prog_unit_error
134         (
135          p_module_name => 'CREATE_POE_RT'
136         ,p_hook_type   => 'BP'
137         );
138     --
139     -- End of API User Hook for the before hook of create_POE_RT
140     --
141   end;
142   --
143   ben_prt_ins.ins
144     (
145      p_poe_rt_id                     => l_poe_rt_id
146     ,p_effective_start_date          => l_effective_start_date
147     ,p_effective_end_date            => l_effective_end_date
148     ,p_mn_poe_num                    => p_mn_poe_num
149     ,p_mx_poe_num                    => p_mx_poe_num
150     ,p_no_mn_poe_flag                => p_no_mn_poe_flag
151     ,p_no_mx_poe_flag                => p_no_mx_poe_flag
152     ,p_rndg_cd                       => p_rndg_cd
153     ,p_rndg_rl                       => p_rndg_rl
154     ,p_poe_nnmntry_uom               => p_poe_nnmntry_uom
155     ,p_vrbl_rt_prfl_id               => p_vrbl_rt_prfl_id
156     ,p_business_group_id             => p_business_group_id
157     ,p_prt_attribute_category        => p_prt_attribute_category
158     ,p_prt_attribute1                => p_prt_attribute1
159     ,p_prt_attribute2                => p_prt_attribute2
160     ,p_prt_attribute3                => p_prt_attribute3
161     ,p_prt_attribute4                => p_prt_attribute4
162     ,p_prt_attribute5                => p_prt_attribute5
163     ,p_prt_attribute6                => p_prt_attribute6
164     ,p_prt_attribute7                => p_prt_attribute7
165     ,p_prt_attribute8                => p_prt_attribute8
166     ,p_prt_attribute9                => p_prt_attribute9
167     ,p_prt_attribute10               => p_prt_attribute10
168     ,p_prt_attribute11               => p_prt_attribute11
169     ,p_prt_attribute12               => p_prt_attribute12
170     ,p_prt_attribute13               => p_prt_attribute13
171     ,p_prt_attribute14               => p_prt_attribute14
172     ,p_prt_attribute15               => p_prt_attribute15
173     ,p_prt_attribute16               => p_prt_attribute16
174     ,p_prt_attribute17               => p_prt_attribute17
175     ,p_prt_attribute18               => p_prt_attribute18
176     ,p_prt_attribute19               => p_prt_attribute19
177     ,p_prt_attribute20               => p_prt_attribute20
178     ,p_prt_attribute21               => p_prt_attribute21
179     ,p_prt_attribute22               => p_prt_attribute22
180     ,p_prt_attribute23               => p_prt_attribute23
181     ,p_prt_attribute24               => p_prt_attribute24
182     ,p_prt_attribute25               => p_prt_attribute25
183     ,p_prt_attribute26               => p_prt_attribute26
184     ,p_prt_attribute27               => p_prt_attribute27
185     ,p_prt_attribute28               => p_prt_attribute28
186     ,p_prt_attribute29               => p_prt_attribute29
187     ,p_prt_attribute30               => p_prt_attribute30
188     ,p_object_version_number         => l_object_version_number
189     ,p_cbr_dsblty_apls_flag          => p_cbr_dsblty_apls_flag
190     ,p_effective_date                => trunc(p_effective_date)
191     );
192   --
193   begin
194     --
195     -- Start of API User Hook for the after hook of create_POE_RT
196     --
197     ben_POE_RT_bk1.create_POE_RT_a
198       (
199        p_poe_rt_id                      =>  l_poe_rt_id
200       ,p_effective_start_date           =>  l_effective_start_date
201       ,p_effective_end_date             =>  l_effective_end_date
202       ,p_mn_poe_num                     =>  p_mn_poe_num
203       ,p_mx_poe_num                     =>  p_mx_poe_num
204       ,p_no_mn_poe_flag                 =>  p_no_mn_poe_flag
205       ,p_no_mx_poe_flag                 =>  p_no_mx_poe_flag
206       ,p_rndg_cd                        =>  p_rndg_cd
207       ,p_rndg_rl                        =>  p_rndg_rl
208       ,p_poe_nnmntry_uom                =>  p_poe_nnmntry_uom
209       ,p_vrbl_rt_prfl_id                =>  p_vrbl_rt_prfl_id
210       ,p_business_group_id              =>  p_business_group_id
211       ,p_prt_attribute_category         =>  p_prt_attribute_category
212       ,p_prt_attribute1                 =>  p_prt_attribute1
213       ,p_prt_attribute2                 =>  p_prt_attribute2
214       ,p_prt_attribute3                 =>  p_prt_attribute3
215       ,p_prt_attribute4                 =>  p_prt_attribute4
216       ,p_prt_attribute5                 =>  p_prt_attribute5
217       ,p_prt_attribute6                 =>  p_prt_attribute6
218       ,p_prt_attribute7                 =>  p_prt_attribute7
219       ,p_prt_attribute8                 =>  p_prt_attribute8
220       ,p_prt_attribute9                 =>  p_prt_attribute9
221       ,p_prt_attribute10                =>  p_prt_attribute10
222       ,p_prt_attribute11                =>  p_prt_attribute11
223       ,p_prt_attribute12                =>  p_prt_attribute12
224       ,p_prt_attribute13                =>  p_prt_attribute13
225       ,p_prt_attribute14                =>  p_prt_attribute14
226       ,p_prt_attribute15                =>  p_prt_attribute15
227       ,p_prt_attribute16                =>  p_prt_attribute16
228       ,p_prt_attribute17                =>  p_prt_attribute17
229       ,p_prt_attribute18                =>  p_prt_attribute18
230       ,p_prt_attribute19                =>  p_prt_attribute19
231       ,p_prt_attribute20                =>  p_prt_attribute20
232       ,p_prt_attribute21                =>  p_prt_attribute21
233       ,p_prt_attribute22                =>  p_prt_attribute22
234       ,p_prt_attribute23                =>  p_prt_attribute23
235       ,p_prt_attribute24                =>  p_prt_attribute24
236       ,p_prt_attribute25                =>  p_prt_attribute25
237       ,p_prt_attribute26                =>  p_prt_attribute26
238       ,p_prt_attribute27                =>  p_prt_attribute27
239       ,p_prt_attribute28                =>  p_prt_attribute28
240       ,p_prt_attribute29                =>  p_prt_attribute29
241       ,p_prt_attribute30                =>  p_prt_attribute30
242       ,p_object_version_number          =>  l_object_version_number
243       ,p_cbr_dsblty_apls_flag           =>  p_cbr_dsblty_apls_flag
244       ,p_effective_date                      => trunc(p_effective_date)
245       );
246   exception
247     when hr_api.cannot_find_prog_unit then
248       hr_api.cannot_find_prog_unit_error
249         (p_module_name => 'CREATE_POE_RT'
250         ,p_hook_type   => 'AP'
251         );
252     --
253     -- End of API User Hook for the after hook of create_POE_RT
254     --
255   end;
256   --
257   ben_profile_handler.event_handler
258     (p_event                       => 'CREATE',
259      p_base_table                  => 'BEN_VRBL_RT_PRFL_F',
260      p_base_table_column           => 'VRBL_RT_PRFL_ID',
261      p_base_table_column_value     => p_vrbl_rt_prfl_id,
262      p_base_table_reference_column => 'RT_POE_FLAG',
263      p_reference_table             => 'BEN_POE_RT_F',
264      p_reference_table_column      => 'VRBL_RT_PRFL_ID');
265   --
266   hr_utility.set_location(l_proc, 60);
267   --
268   -- When in validation only mode raise the Validate_Enabled exception
269   --
270   if p_validate then
271     raise hr_api.validate_enabled;
272   end if;
273   --
274   -- Set all output arguments
275   --
276   p_poe_rt_id := l_poe_rt_id;
277   p_effective_start_date := l_effective_start_date;
278   p_effective_end_date := l_effective_end_date;
279   p_object_version_number := l_object_version_number;
280   --
281   hr_utility.set_location(' Leaving:'||l_proc, 70);
282   --
283 exception
284   --
285   when hr_api.validate_enabled then
286     --
287     -- As the Validate_Enabled exception has been raised
288     -- we must rollback to the savepoint
289     --
290     ROLLBACK TO create_POE_RT;
291     --
292     -- Only set output warning arguments
293     -- (Any key or derived arguments must be set to null
294     -- when validation only mode is being used.)
295     --
296     p_poe_rt_id := null;
297     p_effective_start_date := null;
298     p_effective_end_date := null;
299     p_object_version_number  := null;
300     hr_utility.set_location(' Leaving:'||l_proc, 80);
301     --
302   when others then
303     --
304     -- A validation or unexpected error has occured
305     --
306     ROLLBACK TO create_POE_RT;
307     p_poe_rt_id := null;
308     p_effective_start_date := null;
309     p_effective_end_date := null;
310     p_object_version_number  := null;
311     raise;
312     --
313 end create_POE_RT;
314 -- ----------------------------------------------------------------------------
315 -- |------------------------< update_POE_RT >--- ------------------|
316 -- ----------------------------------------------------------------------------
317 --
318 procedure update_POE_RT
319   (p_validate                       in  boolean   default false
320   ,p_poe_rt_id                      in  number
321   ,p_effective_start_date           out nocopy date
322   ,p_effective_end_date             out nocopy date
323   ,p_mn_poe_num                     in  number    default hr_api.g_number
324   ,p_mx_poe_num                     in  number    default hr_api.g_number
325   ,p_no_mn_poe_flag                 in  varchar2  default hr_api.g_varchar2
326   ,p_no_mx_poe_flag                 in  varchar2  default hr_api.g_varchar2
327   ,p_rndg_cd                        in  varchar2  default hr_api.g_varchar2
331   ,p_business_group_id              in  number    default hr_api.g_number
328   ,p_rndg_rl                        in  number    default hr_api.g_number
329   ,p_poe_nnmntry_uom                in  varchar2  default hr_api.g_varchar2
330   ,p_vrbl_rt_prfl_id                in  number    default hr_api.g_number
332   ,p_prt_attribute_category         in  varchar2  default hr_api.g_varchar2
333   ,p_prt_attribute1                 in  varchar2  default hr_api.g_varchar2
334   ,p_prt_attribute2                 in  varchar2  default hr_api.g_varchar2
335   ,p_prt_attribute3                 in  varchar2  default hr_api.g_varchar2
336   ,p_prt_attribute4                 in  varchar2  default hr_api.g_varchar2
337   ,p_prt_attribute5                 in  varchar2  default hr_api.g_varchar2
338   ,p_prt_attribute6                 in  varchar2  default hr_api.g_varchar2
339   ,p_prt_attribute7                 in  varchar2  default hr_api.g_varchar2
340   ,p_prt_attribute8                 in  varchar2  default hr_api.g_varchar2
341   ,p_prt_attribute9                 in  varchar2  default hr_api.g_varchar2
342   ,p_prt_attribute10                in  varchar2  default hr_api.g_varchar2
343   ,p_prt_attribute11                in  varchar2  default hr_api.g_varchar2
344   ,p_prt_attribute12                in  varchar2  default hr_api.g_varchar2
345   ,p_prt_attribute13                in  varchar2  default hr_api.g_varchar2
346   ,p_prt_attribute14                in  varchar2  default hr_api.g_varchar2
347   ,p_prt_attribute15                in  varchar2  default hr_api.g_varchar2
348   ,p_prt_attribute16                in  varchar2  default hr_api.g_varchar2
349   ,p_prt_attribute17                in  varchar2  default hr_api.g_varchar2
350   ,p_prt_attribute18                in  varchar2  default hr_api.g_varchar2
351   ,p_prt_attribute19                in  varchar2  default hr_api.g_varchar2
352   ,p_prt_attribute20                in  varchar2  default hr_api.g_varchar2
353   ,p_prt_attribute21                in  varchar2  default hr_api.g_varchar2
354   ,p_prt_attribute22                in  varchar2  default hr_api.g_varchar2
355   ,p_prt_attribute23                in  varchar2  default hr_api.g_varchar2
356   ,p_prt_attribute24                in  varchar2  default hr_api.g_varchar2
357   ,p_prt_attribute25                in  varchar2  default hr_api.g_varchar2
358   ,p_prt_attribute26                in  varchar2  default hr_api.g_varchar2
359   ,p_prt_attribute27                in  varchar2  default hr_api.g_varchar2
360   ,p_prt_attribute28                in  varchar2  default hr_api.g_varchar2
361   ,p_prt_attribute29                in  varchar2  default hr_api.g_varchar2
362   ,p_prt_attribute30                in  varchar2  default hr_api.g_varchar2
363   ,p_object_version_number          in out nocopy number
364   ,p_cbr_dsblty_apls_flag           in  varchar2  default hr_api.g_varchar2
365   ,p_effective_date                 in  date
366   ,p_datetrack_mode                 in  varchar2
367   ) is
368   --
369   -- Declare cursors and local variables
370   --
371   l_proc varchar2(72) := g_package||'update_POE_RT';
372   l_object_version_number ben_poe_rt_f.object_version_number%TYPE;
373   l_effective_start_date ben_poe_rt_f.effective_start_date%TYPE;
374   l_effective_end_date ben_poe_rt_f.effective_end_date%TYPE;
375   --
376 begin
377   --
378   hr_utility.set_location('Entering:'|| l_proc, 10);
379   --
380   -- Issue a savepoint if operating in validation only mode
381   --
382   savepoint update_POE_RT;
383   --
384   hr_utility.set_location(l_proc, 20);
385   --
386   -- Process Logic
387   --
388   l_object_version_number := p_object_version_number;
389   --
390   begin
391     --
392     -- Start of API User Hook for the before hook of update_POE_RT
393     --
394     ben_POE_RT_bk2.update_POE_RT_b
395       (
396        p_poe_rt_id                      =>  p_poe_rt_id
397       ,p_mn_poe_num                     =>  p_mn_poe_num
398       ,p_mx_poe_num                     =>  p_mx_poe_num
399       ,p_no_mn_poe_flag                 =>  p_no_mn_poe_flag
400       ,p_no_mx_poe_flag                 =>  p_no_mx_poe_flag
401       ,p_rndg_cd                        =>  p_rndg_cd
402       ,p_rndg_rl                        =>  p_rndg_rl
403       ,p_poe_nnmntry_uom                =>  p_poe_nnmntry_uom
404       ,p_vrbl_rt_prfl_id                =>  p_vrbl_rt_prfl_id
405       ,p_business_group_id              =>  p_business_group_id
406       ,p_prt_attribute_category         =>  p_prt_attribute_category
407       ,p_prt_attribute1                 =>  p_prt_attribute1
408       ,p_prt_attribute2                 =>  p_prt_attribute2
409       ,p_prt_attribute3                 =>  p_prt_attribute3
410       ,p_prt_attribute4                 =>  p_prt_attribute4
411       ,p_prt_attribute5                 =>  p_prt_attribute5
412       ,p_prt_attribute6                 =>  p_prt_attribute6
413       ,p_prt_attribute7                 =>  p_prt_attribute7
414       ,p_prt_attribute8                 =>  p_prt_attribute8
415       ,p_prt_attribute9                 =>  p_prt_attribute9
416       ,p_prt_attribute10                =>  p_prt_attribute10
417       ,p_prt_attribute11                =>  p_prt_attribute11
418       ,p_prt_attribute12                =>  p_prt_attribute12
419       ,p_prt_attribute13                =>  p_prt_attribute13
420       ,p_prt_attribute14                =>  p_prt_attribute14
421       ,p_prt_attribute15                =>  p_prt_attribute15
422       ,p_prt_attribute16                =>  p_prt_attribute16
423       ,p_prt_attribute17                =>  p_prt_attribute17
427       ,p_prt_attribute21                =>  p_prt_attribute21
424       ,p_prt_attribute18                =>  p_prt_attribute18
425       ,p_prt_attribute19                =>  p_prt_attribute19
426       ,p_prt_attribute20                =>  p_prt_attribute20
428       ,p_prt_attribute22                =>  p_prt_attribute22
429       ,p_prt_attribute23                =>  p_prt_attribute23
430       ,p_prt_attribute24                =>  p_prt_attribute24
431       ,p_prt_attribute25                =>  p_prt_attribute25
432       ,p_prt_attribute26                =>  p_prt_attribute26
433       ,p_prt_attribute27                =>  p_prt_attribute27
434       ,p_prt_attribute28                =>  p_prt_attribute28
435       ,p_prt_attribute29                =>  p_prt_attribute29
436       ,p_prt_attribute30                =>  p_prt_attribute30
437       ,p_object_version_number          =>  p_object_version_number
438       ,p_cbr_dsblty_apls_flag           =>  p_cbr_dsblty_apls_flag
439     ,p_effective_date                      => trunc(p_effective_date)
440     ,p_datetrack_mode                      => p_datetrack_mode
441       );
442   exception
443     when hr_api.cannot_find_prog_unit then
444       hr_api.cannot_find_prog_unit_error
445         (p_module_name => 'UPDATE_POE_RT'
446         ,p_hook_type   => 'BP'
447         );
448     --
449     -- End of API User Hook for the before hook of update_POE_RT
450     --
451   end;
452   --
453   ben_prt_upd.upd
454     (
455      p_poe_rt_id                     => p_poe_rt_id
456     ,p_effective_start_date          => l_effective_start_date
457     ,p_effective_end_date            => l_effective_end_date
458     ,p_mn_poe_num                    => p_mn_poe_num
459     ,p_mx_poe_num                    => p_mx_poe_num
460     ,p_no_mn_poe_flag                => p_no_mn_poe_flag
461     ,p_no_mx_poe_flag                => p_no_mx_poe_flag
462     ,p_rndg_cd                       => p_rndg_cd
463     ,p_rndg_rl                       => p_rndg_rl
464     ,p_poe_nnmntry_uom               => p_poe_nnmntry_uom
465     ,p_vrbl_rt_prfl_id               => p_vrbl_rt_prfl_id
466     ,p_business_group_id             => p_business_group_id
467     ,p_prt_attribute_category        => p_prt_attribute_category
468     ,p_prt_attribute1                => p_prt_attribute1
469     ,p_prt_attribute2                => p_prt_attribute2
470     ,p_prt_attribute3                => p_prt_attribute3
471     ,p_prt_attribute4                => p_prt_attribute4
472     ,p_prt_attribute5                => p_prt_attribute5
473     ,p_prt_attribute6                => p_prt_attribute6
474     ,p_prt_attribute7                => p_prt_attribute7
475     ,p_prt_attribute8                => p_prt_attribute8
476     ,p_prt_attribute9                => p_prt_attribute9
477     ,p_prt_attribute10               => p_prt_attribute10
478     ,p_prt_attribute11               => p_prt_attribute11
479     ,p_prt_attribute12               => p_prt_attribute12
480     ,p_prt_attribute13               => p_prt_attribute13
481     ,p_prt_attribute14               => p_prt_attribute14
482     ,p_prt_attribute15               => p_prt_attribute15
483     ,p_prt_attribute16               => p_prt_attribute16
484     ,p_prt_attribute17               => p_prt_attribute17
485     ,p_prt_attribute18               => p_prt_attribute18
486     ,p_prt_attribute19               => p_prt_attribute19
487     ,p_prt_attribute20               => p_prt_attribute20
488     ,p_prt_attribute21               => p_prt_attribute21
489     ,p_prt_attribute22               => p_prt_attribute22
490     ,p_prt_attribute23               => p_prt_attribute23
491     ,p_prt_attribute24               => p_prt_attribute24
492     ,p_prt_attribute25               => p_prt_attribute25
493     ,p_prt_attribute26               => p_prt_attribute26
494     ,p_prt_attribute27               => p_prt_attribute27
495     ,p_prt_attribute28               => p_prt_attribute28
496     ,p_prt_attribute29               => p_prt_attribute29
497     ,p_prt_attribute30               => p_prt_attribute30
498     ,p_object_version_number         => l_object_version_number
499     ,p_cbr_dsblty_apls_flag          => p_cbr_dsblty_apls_flag
500     ,p_effective_date                => trunc(p_effective_date)
501     ,p_datetrack_mode                => p_datetrack_mode
502     );
503   --
504   begin
505     --
506     -- Start of API User Hook for the after hook of update_POE_RT
507     --
508     ben_POE_RT_bk2.update_POE_RT_a
509       (
510        p_poe_rt_id                      =>  p_poe_rt_id
511       ,p_effective_start_date           =>  l_effective_start_date
512       ,p_effective_end_date             =>  l_effective_end_date
513       ,p_mn_poe_num                     =>  p_mn_poe_num
514       ,p_mx_poe_num                     =>  p_mx_poe_num
515       ,p_no_mn_poe_flag                 =>  p_no_mn_poe_flag
516       ,p_no_mx_poe_flag                 =>  p_no_mx_poe_flag
517       ,p_rndg_cd                        =>  p_rndg_cd
518       ,p_rndg_rl                        =>  p_rndg_rl
519       ,p_poe_nnmntry_uom                =>  p_poe_nnmntry_uom
520       ,p_vrbl_rt_prfl_id                =>  p_vrbl_rt_prfl_id
521       ,p_business_group_id              =>  p_business_group_id
522       ,p_prt_attribute_category         =>  p_prt_attribute_category
523       ,p_prt_attribute1                 =>  p_prt_attribute1
524       ,p_prt_attribute2                 =>  p_prt_attribute2
525       ,p_prt_attribute3                 =>  p_prt_attribute3
526       ,p_prt_attribute4                 =>  p_prt_attribute4
530       ,p_prt_attribute8                 =>  p_prt_attribute8
527       ,p_prt_attribute5                 =>  p_prt_attribute5
528       ,p_prt_attribute6                 =>  p_prt_attribute6
529       ,p_prt_attribute7                 =>  p_prt_attribute7
531       ,p_prt_attribute9                 =>  p_prt_attribute9
532       ,p_prt_attribute10                =>  p_prt_attribute10
533       ,p_prt_attribute11                =>  p_prt_attribute11
534       ,p_prt_attribute12                =>  p_prt_attribute12
535       ,p_prt_attribute13                =>  p_prt_attribute13
536       ,p_prt_attribute14                =>  p_prt_attribute14
537       ,p_prt_attribute15                =>  p_prt_attribute15
538       ,p_prt_attribute16                =>  p_prt_attribute16
539       ,p_prt_attribute17                =>  p_prt_attribute17
540       ,p_prt_attribute18                =>  p_prt_attribute18
541       ,p_prt_attribute19                =>  p_prt_attribute19
542       ,p_prt_attribute20                =>  p_prt_attribute20
543       ,p_prt_attribute21                =>  p_prt_attribute21
544       ,p_prt_attribute22                =>  p_prt_attribute22
545       ,p_prt_attribute23                =>  p_prt_attribute23
546       ,p_prt_attribute24                =>  p_prt_attribute24
547       ,p_prt_attribute25                =>  p_prt_attribute25
548       ,p_prt_attribute26                =>  p_prt_attribute26
549       ,p_prt_attribute27                =>  p_prt_attribute27
550       ,p_prt_attribute28                =>  p_prt_attribute28
551       ,p_prt_attribute29                =>  p_prt_attribute29
552       ,p_prt_attribute30                =>  p_prt_attribute30
553       ,p_object_version_number          =>  l_object_version_number
554       ,p_cbr_dsblty_apls_flag           =>  p_cbr_dsblty_apls_flag
555       ,p_effective_date                     => trunc(p_effective_date)
556       ,p_datetrack_mode                     => p_datetrack_mode
557       );
558   exception
559     when hr_api.cannot_find_prog_unit then
560       hr_api.cannot_find_prog_unit_error
561         (p_module_name => 'UPDATE_POE_RT'
562         ,p_hook_type   => 'AP'
563         );
564     --
565     -- End of API User Hook for the after hook of update_POE_RT
566     --
567   end;
568   --
569   hr_utility.set_location(l_proc, 60);
570   --
571   -- When in validation only mode raise the Validate_Enabled exception
572   --
573   if p_validate then
574     raise hr_api.validate_enabled;
575   end if;
576   --
577   -- Set all output arguments
578   --
579   p_object_version_number := l_object_version_number;
580   p_effective_start_date := l_effective_start_date;
581   p_effective_end_date := l_effective_end_date;
582   --
583   hr_utility.set_location(' Leaving:'||l_proc, 70);
584   --
585 exception
586   --
587   when hr_api.validate_enabled then
588     --
589     -- As the Validate_Enabled exception has been raised
590     -- we must rollback to the savepoint
591     --
592     ROLLBACK TO update_POE_RT;
593     --
594     -- Only set output warning arguments
595     -- (Any key or derived arguments must be set to null
596     -- when validation only mode is being used.)
597     --
598     p_effective_start_date := null;
599     p_effective_end_date := null;
600     hr_utility.set_location(' Leaving:'||l_proc, 80);
601     --
602   when others then
603     --
604     -- A validation or unexpected error has occured
605     --
606     ROLLBACK TO update_POE_RT;
607     p_effective_start_date := null;
608     p_effective_end_date := null;
609     raise;
610     --
611 end update_POE_RT;
612 -- ----------------------------------------------------------------------------
613 -- |------------------------< delete_POE_RT >----------------------|
614 -- ----------------------------------------------------------------------------
615 --
616 procedure delete_POE_RT
617   (p_validate                       in  boolean  default false
618   ,p_poe_rt_id                      in  number
619   ,p_effective_start_date           out nocopy date
620   ,p_effective_end_date             out nocopy date
621   ,p_object_version_number          in out nocopy number
622   ,p_effective_date                 in  date
623   ,p_datetrack_mode                 in  varchar2
624   ) is
625   --
626   -- Declare cursors and local variables
627   --
628   l_proc varchar2(72) := g_package||'update_POE_RT';
629   l_object_version_number ben_poe_rt_f.object_version_number%TYPE;
630   l_effective_start_date ben_poe_rt_f.effective_start_date%TYPE;
631   l_effective_end_date ben_poe_rt_f.effective_end_date%TYPE;
632   --
633 begin
634   --
635   hr_utility.set_location('Entering:'|| l_proc, 10);
636   --
637   -- Issue a savepoint if operating in validation only mode
638   --
639   savepoint delete_POE_RT;
640   --
641   hr_utility.set_location(l_proc, 20);
642   --
643   -- Process Logic
644   --
645   l_object_version_number := p_object_version_number;
646   --
647   --
648   begin
649     --
650     -- Start of API User Hook for the before hook of delete_POE_RT
651     --
652     ben_POE_RT_bk3.delete_POE_RT_b
653       (
654        p_poe_rt_id                      =>  p_poe_rt_id
655       ,p_object_version_number          =>  p_object_version_number
656     ,p_effective_date                      => trunc(p_effective_date)
660     when hr_api.cannot_find_prog_unit then
657     ,p_datetrack_mode                      => p_datetrack_mode
658       );
659   exception
661       hr_api.cannot_find_prog_unit_error
662         (p_module_name => 'DELETE_POE_RT'
663         ,p_hook_type   => 'BP'
664         );
665     --
666     -- End of API User Hook for the before hook of delete_POE_RT
667     --
671     (
668   end;
669   --
670   ben_prt_del.del
672      p_poe_rt_id                     => p_poe_rt_id
673     ,p_effective_start_date          => l_effective_start_date
674     ,p_effective_end_date            => l_effective_end_date
675     ,p_object_version_number         => l_object_version_number
676     ,p_effective_date                => p_effective_date
677     ,p_datetrack_mode                => p_datetrack_mode
678     );
679   --
680   begin
681     --
682     -- Start of API User Hook for the after hook of delete_POE_RT
683     --
684     ben_POE_RT_bk3.delete_POE_RT_a
685       (
686        p_poe_rt_id                      =>  p_poe_rt_id
687       ,p_effective_start_date           =>  l_effective_start_date
688       ,p_effective_end_date             =>  l_effective_end_date
689       ,p_object_version_number          =>  l_object_version_number
690     ,p_effective_date                      => trunc(p_effective_date)
691     ,p_datetrack_mode                      => p_datetrack_mode
692       );
693   exception
694     when hr_api.cannot_find_prog_unit then
695       hr_api.cannot_find_prog_unit_error
696         (p_module_name => 'DELETE_POE_RT'
697         ,p_hook_type   => 'AP'
698         );
699     --
700     -- End of API User Hook for the after hook of delete_POE_RT
701     --
702   end;
703   --
704   ben_profile_handler.event_handler
705     (p_event                       => 'DELETE',
706      p_base_table                  => 'BEN_VRBL_RT_PRFL_F',
707      p_base_table_column           => 'VRBL_RT_PRFL_ID',
708      p_base_table_column_value     => ben_prt_shd.g_old_rec.vrbl_rt_prfl_id,
709      p_base_table_reference_column => 'RT_POE_FLAG',
710      p_reference_table             => 'BEN_POE_RT_F',
711      p_reference_table_column      => 'VRBL_RT_PRFL_ID');
712   --
713   hr_utility.set_location(l_proc, 60);
714   --
715   -- When in validation only mode raise the Validate_Enabled exception
716   --
717   if p_validate then
718     raise hr_api.validate_enabled;
719   end if;
720   --
721   hr_utility.set_location(' Leaving:'||l_proc, 70);
722   --
723 exception
724   --
725   when hr_api.validate_enabled then
726     --
727     -- As the Validate_Enabled exception has been raised
728     -- we must rollback to the savepoint
729     --
730     ROLLBACK TO delete_POE_RT;
731     --
732     -- Only set output warning arguments
733     -- (Any key or derived arguments must be set to null
734     -- when validation only mode is being used.)
735     --
736     p_effective_start_date := null;
737     p_effective_end_date := null;
738     --
739   when others then
740     --
741     -- A validation or unexpected error has occured
742     --
743     ROLLBACK TO delete_POE_RT;
744     p_effective_start_date := null;
745     p_effective_end_date := null;
746     raise;
747     --
748 end delete_POE_RT;
749 --
750 -- ----------------------------------------------------------------------------
751 -- |-------------------------------< lck >------------------------------------|
752 -- ----------------------------------------------------------------------------
753 --
754 procedure lck
755   (
756    p_poe_rt_id                   in     number
757   ,p_object_version_number          in     number
758   ,p_effective_date                 in     date
759   ,p_datetrack_mode                 in     varchar2
760   ,p_validation_start_date          out nocopy    date
761   ,p_validation_end_date            out nocopy    date
762   ) is
763   --
764   --
765   -- Declare cursors and local variables
766   --
767   l_proc varchar2(72) := g_package||'lck';
768   l_validation_start_date date;
769   l_validation_end_date date;
770   --
771 begin
772   --
773   hr_utility.set_location('Entering:'|| l_proc, 10);
774   --
775   ben_prt_shd.lck
776     (
777       p_poe_rt_id                 => p_poe_rt_id
778      ,p_validation_start_date      => l_validation_start_date
779      ,p_validation_end_date        => l_validation_end_date
780      ,p_object_version_number      => p_object_version_number
781      ,p_effective_date             => p_effective_date
782      ,p_datetrack_mode             => p_datetrack_mode
783     );
784   --
785   hr_utility.set_location(' Leaving:'||l_proc, 70);
786   --
787 end lck;
788 --
789 end ben_POE_RT_api;