DBA Data[Home] [Help]

PACKAGE BODY: APPS.BEN_DPNT_CVRD_OTHR_PL_RT_API

Source


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