DBA Data[Home] [Help]

PACKAGE BODY: APPS.BEN_PRC_UPD

Source


1 Package Body ben_prc_upd as
2 /* $Header: beprcrhi.pkb 120.8 2008/02/05 09:45:19 rtagarra noship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- |                     Private Global Definitions                           |
6 -- ----------------------------------------------------------------------------
7 --
8 g_package  varchar2(33)	:= '  ben_prc_upd.';  -- Global package name
9 --
10 -- ----------------------------------------------------------------------------
11 -- |----------------------------< dt_update_dml >-----------------------------|
12 -- ----------------------------------------------------------------------------
13 -- {Start Of Comments}
14 --
15 -- Description:
16 --   This procedure controls the execution of dml from the datetrack mode
17 --   of CORRECTION only. It is important to note that the object version
18 --   number is only increment by 1 because the datetrack correction is
19 --   soley for one datetracked row.
20 --   This procedure controls the actual dml update logic. The functions of this
21 --   procedure are as follows:
22 --   1) Get the next object_version_number.
23 --   2) To set and unset the g_api_dml status as required (as we are about to
24 --      perform dml).
25 --   3) To update the specified row in the schema using the primary key in
26 --      the predicates.
27 --   4) To trap any constraint violations that may have occurred.
28 --   5) To raise any other errors.
29 --
30 -- Prerequisites:
31 --   This is an internal private procedure which must be called from the
32 --   update_dml procedure.
33 --
34 -- In Parameters:
35 --   A Pl/Sql record structre.
36 --
37 -- Post Success:
38 --   The specified row will be updated in the schema.
39 --
40 -- Post Failure:
41 --   On the update dml failure it is important to note that we always reset the
42 --   g_api_dml status to false.
43 --   If a check or unique integrity constraint violation is raised the
44 --   constraint_error procedure will be called.
45 --   If any other error is reported, the error will be raised after the
46 --   g_api_dml status is reset.
47 --
48 -- Developer Implementation Notes:
49 --   The update 'set' arguments list should be modified if any of your
50 --   attributes are not updateable.
51 --
52 -- Access Status:
53 --   Internal Row Handler Use Only.
54 --
55 -- {End Of Comments}
56 -- ----------------------------------------------------------------------------
57 Procedure dt_update_dml
58 	(p_rec 			 in out nocopy ben_prc_shd.g_rec_type,
59 	 p_effective_date	 in	date,
60 	 p_datetrack_mode	 in	varchar2,
61 	 p_validation_start_date in	date,
62 	 p_validation_end_date	 in	date) is
63 --
64   l_proc	varchar2(72) := g_package||'dt_update_dml';
65 --
66 Begin
67   hr_utility.set_location('Entering:'||l_proc, 5);
68   --
69   If (p_datetrack_mode = 'CORRECTION') then
70     hr_utility.set_location(l_proc, 10);
71     --
72     -- Because we are updating a row we must get the next object
73     -- version number.
74     --
75     p_rec.object_version_number :=
76       dt_api.get_object_version_number
77 	  (p_base_table_name	=> 'ben_prtt_reimbmt_rqst_f',
78 	   p_base_key_column	=> 'prtt_reimbmt_rqst_id',
79 	   p_base_key_value	=> p_rec.prtt_reimbmt_rqst_id);
80     --
81     ben_prc_shd.g_api_dml := true;  -- Set the api dml status
82     --
83     -- Update the ben_prtt_reimbmt_rqst_f Row
84     --
85     update  ben_prtt_reimbmt_rqst_f
86     set
87         prtt_reimbmt_rqst_id        = p_rec.prtt_reimbmt_rqst_id,
88     incrd_from_dt                   = p_rec.incrd_from_dt,
89     incrd_to_dt                     = p_rec.incrd_to_dt,
90     rqst_num                        = p_rec.rqst_num,
91     rqst_amt                        = p_rec.rqst_amt,
92     rqst_amt_uom                    = p_rec.rqst_amt_uom,
93     rqst_btch_num                   = p_rec.rqst_btch_num,
94     prtt_reimbmt_rqst_stat_cd       = p_rec.prtt_reimbmt_rqst_stat_cd,
95     reimbmt_ctfn_typ_prvdd_cd       = p_rec.reimbmt_ctfn_typ_prvdd_cd,
96     rcrrg_cd                        = p_rec.rcrrg_cd,
97     submitter_person_id             = p_rec.submitter_person_id,
98     recipient_person_id             = p_rec.recipient_person_id,
99     provider_person_id              = p_rec.provider_person_id,
100     provider_ssn_person_id          = p_rec.provider_ssn_person_id,
101     pl_id                           = p_rec.pl_id,
102     gd_or_svc_typ_id                = p_rec.gd_or_svc_typ_id,
103     contact_relationship_id         = p_rec.contact_relationship_id,
104     business_group_id               = p_rec.business_group_id,
105     opt_id                          = p_rec.opt_id,
106     popl_yr_perd_id_1               = p_rec.popl_yr_perd_id_1,
107     popl_yr_perd_id_2               = p_rec.popl_yr_perd_id_2 ,
108     amt_year1                       = p_rec.amt_year1 ,
109     amt_year2                       = p_rec.amt_year2 ,
110     prc_attribute_category          = p_rec.prc_attribute_category,
111     prc_attribute1                  = p_rec.prc_attribute1,
112     prc_attribute2                  = p_rec.prc_attribute2,
113     prc_attribute3                  = p_rec.prc_attribute3,
114     prc_attribute4                  = p_rec.prc_attribute4,
115     prc_attribute5                  = p_rec.prc_attribute5,
116     prc_attribute6                  = p_rec.prc_attribute6,
117     prc_attribute7                  = p_rec.prc_attribute7,
118     prc_attribute8                  = p_rec.prc_attribute8,
119     prc_attribute9                  = p_rec.prc_attribute9,
120     prc_attribute10                 = p_rec.prc_attribute10,
121     prc_attribute11                 = p_rec.prc_attribute11,
122     prc_attribute12                 = p_rec.prc_attribute12,
123     prc_attribute13                 = p_rec.prc_attribute13,
124     prc_attribute14                 = p_rec.prc_attribute14,
125     prc_attribute15                 = p_rec.prc_attribute15,
126     prc_attribute16                 = p_rec.prc_attribute16,
127     prc_attribute17                 = p_rec.prc_attribute17,
128     prc_attribute18                 = p_rec.prc_attribute18,
129     prc_attribute19                 = p_rec.prc_attribute19,
130     prc_attribute20                 = p_rec.prc_attribute20,
131     prc_attribute21                 = p_rec.prc_attribute21,
132     prc_attribute22                 = p_rec.prc_attribute22,
133     prc_attribute23                 = p_rec.prc_attribute23,
134     prc_attribute24                 = p_rec.prc_attribute24,
135     prc_attribute25                 = p_rec.prc_attribute25,
136     prc_attribute26                 = p_rec.prc_attribute26,
137     prc_attribute27                 = p_rec.prc_attribute27,
138     prc_attribute28                 = p_rec.prc_attribute28,
139     prc_attribute29                 = p_rec.prc_attribute29,
140     prc_attribute30                 = p_rec.prc_attribute30,
141     prtt_enrt_rslt_id               = p_rec.prtt_enrt_rslt_id,
142     comment_id                      = p_rec.comment_id  ,
143     object_version_number           = p_rec.object_version_number ,
144     stat_rsn_cd                     = p_rec.stat_rsn_cd ,
145     pymt_stat_cd                    = p_rec.pymt_stat_cd ,
146     pymt_stat_rsn_cd                = p_rec.pymt_stat_rsn_cd ,
147     stat_ovrdn_flag                 = p_rec.stat_ovrdn_flag ,
148     stat_ovrdn_rsn_cd               = p_rec.stat_ovrdn_rsn_cd ,
149     stat_prr_to_ovrd                = p_rec.stat_prr_to_ovrd ,
150     pymt_stat_ovrdn_flag            = p_rec.pymt_stat_ovrdn_flag ,
151     pymt_stat_ovrdn_rsn_cd          = p_rec.pymt_stat_ovrdn_rsn_cd ,
152     pymt_stat_prr_to_ovrd           = p_rec.pymt_stat_prr_to_ovrd ,
153     adjmt_flag                      = p_rec.adjmt_flag ,
154     submtd_dt                       = p_rec.submtd_dt ,
155     ttl_rqst_amt                    = p_rec.ttl_rqst_amt ,
156     aprvd_for_pymt_amt              = p_rec.aprvd_for_pymt_amt ,
157     exp_incurd_dt		    = p_rec.exp_incurd_dt
158     where   prtt_reimbmt_rqst_id    = p_rec.prtt_reimbmt_rqst_id
159     and     effective_start_date    = p_validation_start_date
160     and     effective_end_date      = p_validation_end_date;
161     --
162     ben_prc_shd.g_api_dml := false;   -- Unset the api dml status
163     --
164     -- Set the effective start and end dates
165     --
166     p_rec.effective_start_date := p_validation_start_date;
167     p_rec.effective_end_date   := p_validation_end_date;
168   End If;
169 --
170 hr_utility.set_location(' Leaving:'||l_proc, 15);
171 Exception
172   When hr_api.check_integrity_violated Then
173     -- A check constraint has been violated
174     ben_prc_shd.g_api_dml := false;   -- Unset the api dml status
175     ben_prc_shd.constraint_error
176       (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
177   When hr_api.unique_integrity_violated Then
178     -- Unique integrity has been violated
179     ben_prc_shd.g_api_dml := false;   -- Unset the api dml status
180     ben_prc_shd.constraint_error
181       (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
182   When Others Then
183     ben_prc_shd.g_api_dml := false;   -- Unset the api dml status
184     Raise;
185 End dt_update_dml;
186 --
187 -- ----------------------------------------------------------------------------
188 -- |------------------------------< update_dml >------------------------------|
189 -- ----------------------------------------------------------------------------
190 -- {Start Of Comments}
191 --
192 -- Description:
193 --   This procedure calls the dt_update_dml control logic which handles
194 --   the actual datetrack dml.
195 --
196 -- Prerequisites:
197 --   This is an internal private procedure which must be called from the upd
198 --   procedure.
199 --
200 -- In Parameters:
201 --   A Pl/Sql record structre.
202 --
203 -- Post Success:
204 --   Processing contines.
205 --
206 -- Post Failure:
207 --   No specific error handling is required within this procedure.
208 --
209 -- Developer Implementation Notes:
210 --   The update 'set' arguments list should be modified if any of your
211 --   attributes are not updateable.
212 --
213 -- Access Status:
214 --   Internal Row Handler Use Only.
215 --
216 -- {End Of Comments}
217 -- ----------------------------------------------------------------------------
218 Procedure update_dml
219 	(p_rec 			 in out nocopy ben_prc_shd.g_rec_type,
220 	 p_effective_date	 in	date,
221 	 p_datetrack_mode	 in	varchar2,
222 	 p_validation_start_date in	date,
223 	 p_validation_end_date	 in	date) is
224 --
225   l_proc	varchar2(72) := g_package||'update_dml';
226 --
227 Begin
228   hr_utility.set_location('Entering:'||l_proc, 5);
229   --
230   dt_update_dml(p_rec			=> p_rec,
231 		p_effective_date	=> p_effective_date,
232 		p_datetrack_mode	=> p_datetrack_mode,
233        		p_validation_start_date	=> p_validation_start_date,
234 		p_validation_end_date	=> p_validation_end_date);
235   --
236   hr_utility.set_location(' Leaving:'||l_proc, 10);
237 End update_dml;
238 --
239 -- ----------------------------------------------------------------------------
240 -- |----------------------------< dt_pre_update >-----------------------------|
241 -- ----------------------------------------------------------------------------
242 -- {Start Of Comments}
243 --
244 -- Description:
245 --   The dt_pre_update procedure controls the execution
246 --   of dml for the datetrack modes of: UPDATE, UPDATE_OVERRIDE
247 --   and UPDATE_CHANGE_INSERT only. The execution required is as
248 --   follows:
249 --
250 --   1) Providing the datetrack update mode is not 'CORRECTION'
251 --      then set the effective end date of the current row (this
252 --      will be the validation_start_date - 1).
253 --   2) If the datetrack mode is 'UPDATE_OVERRIDE' then call the
254 --      corresponding delete_dml process to delete any future rows
255 --      where the effective_start_date is greater than or equal to
256 --	the validation_start_date.
257 --   3) Call the insert_dml process to insert the new updated row
258 --      details..
259 --
260 -- Prerequisites:
261 --   This is an internal procedure which is called from the
262 --   pre_update procedure.
263 --
264 -- In Parameters:
265 --
266 -- Post Success:
267 --   Processing continues.
268 --
269 -- Post Failure:
270 --   If an error has occurred, an error message and exception will be raised
271 --   but not handled.
272 --
273 -- Developer Implementation Notes:
274 --   This is an internal procedure which is required by Datetrack. Don't
275 --   remove or modify.
276 --
277 -- Access Status:
278 --   Internal Row Handler Use Only.
279 --
280 -- {End Of Comments}
281 -- ----------------------------------------------------------------------------
282 Procedure dt_pre_update
283 	(p_rec 			 in out nocopy ben_prc_shd.g_rec_type,
284 	 p_effective_date	 in	date,
285 	 p_datetrack_mode	 in	varchar2,
286 	 p_validation_start_date in	date,
287 	 p_validation_end_date	 in	date) is
288 --
289   l_proc	         varchar2(72) := g_package||'dt_pre_update';
290   l_dummy_version_number number;
291 --
292 Begin
293   hr_utility.set_location('Entering:'||l_proc, 5);
294   If (p_datetrack_mode <> 'CORRECTION') then
295     hr_utility.set_location(l_proc, 10);
296     --
297     -- Update the current effective end date
298     --
299     ben_prc_shd.upd_effective_end_date
300      (p_effective_date	       => p_effective_date,
301       p_base_key_value	       => p_rec.prtt_reimbmt_rqst_id,
302       p_new_effective_end_date => (p_validation_start_date - 1),
303       p_validation_start_date  => p_validation_start_date,
304       p_validation_end_date    => p_validation_end_date,
305       p_object_version_number  => l_dummy_version_number);
306     --
307     If (p_datetrack_mode = 'UPDATE_OVERRIDE') then
308       hr_utility.set_location(l_proc, 15);
309       --
310       -- As the datetrack mode is 'UPDATE_OVERRIDE' then we must
311       -- delete any future rows
312       --
313       ben_prc_del.delete_dml
314         (p_rec			 => p_rec,
315 	 p_effective_date	 => p_effective_date,
316 	 p_datetrack_mode	 => p_datetrack_mode,
317 	 p_validation_start_date => p_validation_start_date,
318 	 p_validation_end_date   => p_validation_end_date);
319     End If;
320     hr_utility.set_location(l_proc, 20);
321     --
322     -- We must now insert the updated row
323     --
324     ben_prc_ins.insert_dml
325       (p_rec			=> p_rec,
326        p_effective_date		=> p_effective_date,
327        p_datetrack_mode		=> p_datetrack_mode,
328        p_validation_start_date	=> p_validation_start_date,
329        p_validation_end_date	=> p_validation_end_date);
330   End If;
331   hr_utility.set_location(' Leaving:'||l_proc, 20);
332 End dt_pre_update;
333 --
334 -- ----------------------------------------------------------------------------
335 -- |------------------------------< pre_update >------------------------------|
336 -- ----------------------------------------------------------------------------
337 -- {Start Of Comments}
338 --
339 -- Description:
340 --   This private procedure contains any processing which is required before
341 --   the update dml.
342 --
343 -- Prerequisites:
344 --   This is an internal procedure which is called from the upd procedure.
345 --
346 -- In Parameters:
347 --   A Pl/Sql record structre.
348 --
349 -- Post Success:
350 --   Processing continues.
351 --
352 -- Post Failure:
353 --   If an error has occurred, an error message and exception will be raised
354 --   but not handled.
355 --
356 -- Developer Implementation Notes:
357 --   Any pre-processing required before the update dml is issued should be
358 --   coded within this procedure. It is important to note that any 3rd party
359 --   maintenance should be reviewed before placing in this procedure. The call
360 --   to the dt_update_dml procedure should NOT be removed.
361 --
362 -- Access Status:
363 --   Internal Row Handler Use Only.
364 --
365 -- {End Of Comments}
366 -- ----------------------------------------------------------------------------
367 Procedure pre_update
368 	(p_rec 			 in out nocopy ben_prc_shd.g_rec_type,
369 	 p_effective_date	 in	date,
370 	 p_datetrack_mode	 in	varchar2,
371 	 p_validation_start_date in	date,
372 	 p_validation_end_date	 in	date) is
373 --
374   l_proc	varchar2(72) := g_package||'pre_update';
375 --
376 Begin
377   hr_utility.set_location('Entering:'||l_proc, 5);
378   --
379   --
380   --
381   dt_pre_update
382     (p_rec 		     => p_rec,
383      p_effective_date	     => p_effective_date,
384      p_datetrack_mode	     => p_datetrack_mode,
385      p_validation_start_date => p_validation_start_date,
386      p_validation_end_date   => p_validation_end_date);
387   --
388   hr_utility.set_location(' Leaving:'||l_proc, 10);
389 End pre_update;
390 --
391 -- ----------------------------------------------------------------------------
392 -- |-----------------------------< post_update >------------------------------|
393 -- ----------------------------------------------------------------------------
394 -- {Start Of Comments}
395 --
396 -- Description:
397 --   This private procedure contains any processing which is required after the
398 --   update dml.
399 --
400 -- Prerequisites:
401 --   This is an internal procedure which is called from the upd procedure.
402 --
403 -- In Parameters:
404 --   A Pl/Sql record structre.
405 --
406 -- Post Success:
407 --   Processing continues.
408 --
409 -- Post Failure:
410 --   If an error has occurred, an error message and exception will be raised
411 --   but not handled.
412 --
413 -- Developer Implementation Notes:
414 --   Any post-processing required after the update dml is issued should be
415 --   coded within this procedure. It is important to note that any 3rd party
416 --   maintenance should be reviewed before placing in this procedure.
417 --
418 -- Access Status:
419 --   Internal Row Handler Use Only.
420 --
421 -- {End Of Comments}
422 -- ----------------------------------------------------------------------------
423 Procedure post_update
424 	(p_rec 			 in ben_prc_shd.g_rec_type,
425 	 p_effective_date	 in date,
426 	 p_datetrack_mode	 in varchar2,
427 	 p_validation_start_date in date,
428 	 p_validation_end_date	 in date) is
429 --
430   l_proc	varchar2(72) := g_package||'post_update';
431 --
432 Begin
433   hr_utility.set_location('Entering:'||l_proc, 5);
434 --
435   --
436   -- Start of API User Hook for post_update.
437   --
438   begin
439     --
440     ben_prc_rku.after_update
441       (
442   p_prtt_reimbmt_rqst_id          =>p_rec.prtt_reimbmt_rqst_id
443  ,p_effective_start_date          =>p_rec.effective_start_date
444  ,p_effective_end_date            =>p_rec.effective_end_date
445  ,p_incrd_from_dt                 =>p_rec.incrd_from_dt
446  ,p_incrd_to_dt                   =>p_rec.incrd_to_dt
447  ,p_rqst_num                      =>p_rec.rqst_num
448  ,p_rqst_amt                      =>p_rec.rqst_amt
449  ,p_rqst_amt_uom                  =>p_rec.rqst_amt_uom
450  ,p_rqst_btch_num                 =>p_rec.rqst_btch_num
451  ,p_prtt_reimbmt_rqst_stat_cd     =>p_rec.prtt_reimbmt_rqst_stat_cd
452  ,p_reimbmt_ctfn_typ_prvdd_cd     =>p_rec.reimbmt_ctfn_typ_prvdd_cd
453  ,p_rcrrg_cd                      =>p_rec.rcrrg_cd
454  ,p_submitter_person_id           =>p_rec.submitter_person_id
455  ,p_recipient_person_id           =>p_rec.recipient_person_id
456  ,p_provider_person_id            =>p_rec.provider_person_id
457  ,p_provider_ssn_person_id        =>p_rec.provider_ssn_person_id
458  ,p_pl_id                         =>p_rec.pl_id
459  ,p_gd_or_svc_typ_id              =>p_rec.gd_or_svc_typ_id
460  ,p_contact_relationship_id       =>p_rec.contact_relationship_id
461  ,p_business_group_id             =>p_rec.business_group_id
462  ,p_opt_id                        =>p_rec.opt_id
463  ,p_popl_yr_perd_id_1             =>p_rec.popl_yr_perd_id_1
464  ,p_popl_yr_perd_id_2             =>p_rec.popl_yr_perd_id_2
465  ,p_amt_year1                     =>p_rec.amt_year1
466  ,p_amt_year2                     =>p_rec.amt_year2
467  ,p_prc_attribute_category        =>p_rec.prc_attribute_category
468  ,p_prc_attribute1                =>p_rec.prc_attribute1
469  ,p_prc_attribute2                =>p_rec.prc_attribute2
470  ,p_prc_attribute3                =>p_rec.prc_attribute3
471  ,p_prc_attribute4                =>p_rec.prc_attribute4
472  ,p_prc_attribute5                =>p_rec.prc_attribute5
473  ,p_prc_attribute6                =>p_rec.prc_attribute6
474  ,p_prc_attribute7                =>p_rec.prc_attribute7
475  ,p_prc_attribute8                =>p_rec.prc_attribute8
476  ,p_prc_attribute9                =>p_rec.prc_attribute9
477  ,p_prc_attribute10               =>p_rec.prc_attribute10
478  ,p_prc_attribute11               =>p_rec.prc_attribute11
479  ,p_prc_attribute12               =>p_rec.prc_attribute12
480  ,p_prc_attribute13               =>p_rec.prc_attribute13
481  ,p_prc_attribute14               =>p_rec.prc_attribute14
482  ,p_prc_attribute15               =>p_rec.prc_attribute15
483  ,p_prc_attribute16               =>p_rec.prc_attribute16
484  ,p_prc_attribute17               =>p_rec.prc_attribute17
485  ,p_prc_attribute18               =>p_rec.prc_attribute18
486  ,p_prc_attribute19               =>p_rec.prc_attribute19
487  ,p_prc_attribute20               =>p_rec.prc_attribute20
488  ,p_prc_attribute21               =>p_rec.prc_attribute21
489  ,p_prc_attribute22               =>p_rec.prc_attribute22
490  ,p_prc_attribute23               =>p_rec.prc_attribute23
491  ,p_prc_attribute24               =>p_rec.prc_attribute24
492  ,p_prc_attribute25               =>p_rec.prc_attribute25
493  ,p_prc_attribute26               =>p_rec.prc_attribute26
494  ,p_prc_attribute27               =>p_rec.prc_attribute27
495  ,p_prc_attribute28               =>p_rec.prc_attribute28
496  ,p_prc_attribute29               =>p_rec.prc_attribute29
497  ,p_prc_attribute30               =>p_rec.prc_attribute30
498  ,p_prtt_enrt_rslt_id             =>p_rec.prtt_enrt_rslt_id
499  ,p_comment_id                    =>p_rec.comment_id
500  ,p_object_version_number         =>p_rec.object_version_number
501  ,p_stat_rsn_cd                   =>p_rec.stat_rsn_cd
502  ,p_pymt_stat_cd                  =>p_rec.pymt_stat_cd
503  ,p_pymt_stat_rsn_cd              =>p_rec.pymt_stat_rsn_cd
504  ,p_stat_ovrdn_flag               =>p_rec.stat_ovrdn_flag
505  ,p_stat_ovrdn_rsn_cd             =>p_rec.stat_ovrdn_rsn_cd
506  ,p_stat_prr_to_ovrd              =>p_rec.stat_prr_to_ovrd
507  ,p_pymt_stat_ovrdn_flag          =>p_rec.pymt_stat_ovrdn_flag
508  ,p_pymt_stat_ovrdn_rsn_cd        =>p_rec.pymt_stat_ovrdn_rsn_cd
509  ,p_pymt_stat_prr_to_ovrd         =>p_rec.pymt_stat_prr_to_ovrd
510  ,p_adjmt_flag                    =>p_rec.adjmt_flag
511  ,p_submtd_dt                     =>p_rec.submtd_dt
512  ,p_ttl_rqst_amt                  =>p_rec.ttl_rqst_amt
513  ,p_aprvd_for_pymt_amt            =>p_rec.aprvd_for_pymt_amt
514  ,p_exp_incurd_dt		  =>p_rec.exp_incurd_dt
515  ,p_effective_date                =>p_effective_date
516  ,p_datetrack_mode                =>p_datetrack_mode
517  ,p_validation_start_date         =>p_validation_start_date
518  ,p_validation_end_date           =>p_validation_end_date
519  ,p_effective_start_date_o        =>ben_prc_shd.g_old_rec.effective_start_date
520  ,p_effective_end_date_o          =>ben_prc_shd.g_old_rec.effective_end_date
521  ,p_incrd_from_dt_o               =>ben_prc_shd.g_old_rec.incrd_from_dt
522  ,p_incrd_to_dt_o                 =>ben_prc_shd.g_old_rec.incrd_to_dt
523  ,p_rqst_num_o                    =>ben_prc_shd.g_old_rec.rqst_num
524  ,p_rqst_amt_o                    =>ben_prc_shd.g_old_rec.rqst_amt
525  ,p_rqst_amt_uom_o                =>ben_prc_shd.g_old_rec.rqst_amt_uom
526  ,p_rqst_btch_num_o               =>ben_prc_shd.g_old_rec.rqst_btch_num
527  ,p_prtt_reimbmt_rqst_stat_cd_o   =>ben_prc_shd.g_old_rec.prtt_reimbmt_rqst_stat_cd
528  ,p_reimbmt_ctfn_typ_prvdd_cd_o   =>ben_prc_shd.g_old_rec.reimbmt_ctfn_typ_prvdd_cd
529  ,p_rcrrg_cd_o                    =>ben_prc_shd.g_old_rec.rcrrg_cd
530  ,p_submitter_person_id_o         =>ben_prc_shd.g_old_rec.submitter_person_id
531  ,p_recipient_person_id_o         =>ben_prc_shd.g_old_rec.recipient_person_id
532  ,p_provider_person_id_o          =>ben_prc_shd.g_old_rec.provider_person_id
533  ,p_provider_ssn_person_id_o      =>ben_prc_shd.g_old_rec.provider_ssn_person_id
534  ,p_pl_id_o                       =>ben_prc_shd.g_old_rec.pl_id
535  ,p_gd_or_svc_typ_id_o            =>ben_prc_shd.g_old_rec.gd_or_svc_typ_id
536  ,p_contact_relationship_id_o     =>ben_prc_shd.g_old_rec.contact_relationship_id
537  ,p_business_group_id_o           =>ben_prc_shd.g_old_rec.business_group_id
538  ,p_opt_id_o                        =>ben_prc_shd.g_old_rec.opt_id
539  ,p_popl_yr_perd_id_1_o             =>ben_prc_shd.g_old_rec.popl_yr_perd_id_1
540  ,p_popl_yr_perd_id_2_o             =>ben_prc_shd.g_old_rec.popl_yr_perd_id_2
541  ,p_amt_year1_o                     =>ben_prc_shd.g_old_rec.amt_year1
542  ,p_amt_year2_o                     =>ben_prc_shd.g_old_rec.amt_year2
543  ,p_prc_attribute_category_o      =>ben_prc_shd.g_old_rec.prc_attribute_category
544  ,p_prc_attribute1_o              =>ben_prc_shd.g_old_rec.prc_attribute1
545  ,p_prc_attribute2_o              =>ben_prc_shd.g_old_rec.prc_attribute2
546  ,p_prc_attribute3_o              =>ben_prc_shd.g_old_rec.prc_attribute3
547  ,p_prc_attribute4_o              =>ben_prc_shd.g_old_rec.prc_attribute4
548  ,p_prc_attribute5_o              =>ben_prc_shd.g_old_rec.prc_attribute5
549  ,p_prc_attribute6_o              =>ben_prc_shd.g_old_rec.prc_attribute6
550  ,p_prc_attribute7_o              =>ben_prc_shd.g_old_rec.prc_attribute7
551  ,p_prc_attribute8_o              =>ben_prc_shd.g_old_rec.prc_attribute8
552  ,p_prc_attribute9_o              =>ben_prc_shd.g_old_rec.prc_attribute9
553  ,p_prc_attribute10_o             =>ben_prc_shd.g_old_rec.prc_attribute10
554  ,p_prc_attribute11_o             =>ben_prc_shd.g_old_rec.prc_attribute11
555  ,p_prc_attribute12_o             =>ben_prc_shd.g_old_rec.prc_attribute12
556  ,p_prc_attribute13_o             =>ben_prc_shd.g_old_rec.prc_attribute13
557  ,p_prc_attribute14_o             =>ben_prc_shd.g_old_rec.prc_attribute14
558  ,p_prc_attribute15_o             =>ben_prc_shd.g_old_rec.prc_attribute15
559  ,p_prc_attribute16_o             =>ben_prc_shd.g_old_rec.prc_attribute16
560  ,p_prc_attribute17_o             =>ben_prc_shd.g_old_rec.prc_attribute17
561  ,p_prc_attribute18_o             =>ben_prc_shd.g_old_rec.prc_attribute18
562  ,p_prc_attribute19_o             =>ben_prc_shd.g_old_rec.prc_attribute19
563  ,p_prc_attribute20_o             =>ben_prc_shd.g_old_rec.prc_attribute20
564  ,p_prc_attribute21_o             =>ben_prc_shd.g_old_rec.prc_attribute21
565  ,p_prc_attribute22_o             =>ben_prc_shd.g_old_rec.prc_attribute22
566  ,p_prc_attribute23_o             =>ben_prc_shd.g_old_rec.prc_attribute23
567  ,p_prc_attribute24_o             =>ben_prc_shd.g_old_rec.prc_attribute24
568  ,p_prc_attribute25_o             =>ben_prc_shd.g_old_rec.prc_attribute25
569  ,p_prc_attribute26_o             =>ben_prc_shd.g_old_rec.prc_attribute26
570  ,p_prc_attribute27_o             =>ben_prc_shd.g_old_rec.prc_attribute27
571  ,p_prc_attribute28_o             =>ben_prc_shd.g_old_rec.prc_attribute28
572  ,p_prc_attribute29_o             =>ben_prc_shd.g_old_rec.prc_attribute29
573  ,p_prc_attribute30_o             =>ben_prc_shd.g_old_rec.prc_attribute30
574  ,p_prtt_enrt_rslt_id_o           =>ben_prc_shd.g_old_rec.prtt_enrt_rslt_id
575  ,p_comment_id_o                  =>ben_prc_shd.g_old_rec.comment_id
576  ,p_object_version_number_o       =>ben_prc_shd.g_old_rec.object_version_number
577  ,p_stat_rsn_cd_o                 =>ben_prc_shd.g_old_rec.stat_rsn_cd
578  ,p_pymt_stat_cd_o                =>ben_prc_shd.g_old_rec.pymt_stat_cd
579  ,p_pymt_stat_rsn_cd_o            =>ben_prc_shd.g_old_rec.pymt_stat_rsn_cd
580  ,p_stat_ovrdn_flag_o             =>ben_prc_shd.g_old_rec.stat_ovrdn_flag
581  ,p_stat_ovrdn_rsn_cd_o           =>ben_prc_shd.g_old_rec.stat_ovrdn_rsn_cd
582  ,p_stat_prr_to_ovrd_o            =>ben_prc_shd.g_old_rec.stat_prr_to_ovrd
583  ,p_pymt_stat_ovrdn_flag_o        =>ben_prc_shd.g_old_rec.pymt_stat_ovrdn_flag
584  ,p_pymt_stat_ovrdn_rsn_cd_o      =>ben_prc_shd.g_old_rec.pymt_stat_ovrdn_rsn_cd
585  ,p_pymt_stat_prr_to_ovrd_o       =>ben_prc_shd.g_old_rec.pymt_stat_prr_to_ovrd
586  ,p_adjmt_flag_o                   =>ben_prc_shd.g_old_rec.adjmt_flag
587  ,p_submtd_dt_o                   =>ben_prc_shd.g_old_rec.submtd_dt
588  ,p_ttl_rqst_amt_o                =>ben_prc_shd.g_old_rec.ttl_rqst_amt
589  ,p_aprvd_for_pymt_amt_o          =>ben_prc_shd.g_old_rec.aprvd_for_pymt_amt
590  ,p_exp_incurd_dt_o		  =>ben_prc_shd.g_old_rec.exp_incurd_dt
591   );
592     --
593   exception
594     --
595     when hr_api.cannot_find_prog_unit then
596       --
597       hr_api.cannot_find_prog_unit_error
598         (p_module_name => 'ben_prtt_reimbmt_rqst_f'
599         ,p_hook_type   => 'AU');
600       --
601   end;
602   --
603   -- End of API User Hook for post_update.
604   --
605   --
606   hr_utility.set_location(' Leaving:'||l_proc, 10);
607 End post_update;
608 --
609 -- ----------------------------------------------------------------------------
610 -- |-----------------------------< convert_defs >-----------------------------|
611 -- ----------------------------------------------------------------------------
612 -- {Start Of Comments}
613 --
614 -- Description:
615 --   The Convert_Defs procedure has one very important function:
616 --   It must return the record structure for the row with all system defaulted
617 --   values converted into its corresponding parameter value for update. When
618 --   we attempt to update a row through the Upd process , certain
619 --   parameters can be defaulted which enables flexibility in the calling of
620 --   the upd process (e.g. only attributes which need to be updated need to be
621 --   specified). For the upd process to determine which attributes
622 --   have NOT been specified we need to check if the parameter has a reserved
623 --   system default value. Therefore, for all parameters which have a
624 --   corresponding reserved system default mechanism specified we need to
625 --   check if a system default is being used. If a system default is being
626 --   used then we convert the defaulted value into its corresponding attribute
627 --   value held in the g_old_rec data structure.
628 --
629 -- Prerequisites:
630 --   This private function can only be called from the upd process.
631 --
632 -- In Parameters:
633 --   A Pl/Sql record structre.
634 --
635 -- Post Success:
636 --   The record structure will be returned with all system defaulted parameter
637 --   values converted into its current row attribute value.
638 --
639 -- Post Failure:
640 --   No direct error handling is required within this function. Any possible
641 --   errors within this procedure will be a PL/SQL value error due to conversion
642 --   of datatypes or data lengths.
643 --
644 -- Developer Implementation Notes:
645 --   None.
646 --
647 -- Access Status:
648 --   Internal Row Handler Use Only.
649 --
650 -- {End Of Comments}
651 -- ----------------------------------------------------------------------------
652 Procedure convert_defs(p_rec in out nocopy ben_prc_shd.g_rec_type) is
653 --
654   l_proc  varchar2(72) := g_package||'convert_defs';
655 --
656 Begin
657   --
658   hr_utility.set_location('Entering:'||l_proc, 5);
659   --
660   -- We must now examine each argument value in the
661   -- p_rec plsql record structure
662   -- to see if a system default is being used. If a system default
663   -- is being used then we must set to the 'current' argument value.
664   --
665   If (p_rec.incrd_from_dt = hr_api.g_date) then
666     p_rec.incrd_from_dt :=
667     ben_prc_shd.g_old_rec.incrd_from_dt;
668   End If;
669   If (p_rec.incrd_to_dt = hr_api.g_date) then
670     p_rec.incrd_to_dt :=
671     ben_prc_shd.g_old_rec.incrd_to_dt;
672   End If;
673   If (p_rec.rqst_num = hr_api.g_number) then
674     p_rec.rqst_num :=
675     ben_prc_shd.g_old_rec.rqst_num;
676   End If;
677   If (p_rec.rqst_amt = hr_api.g_number) then
678     p_rec.rqst_amt :=
679     ben_prc_shd.g_old_rec.rqst_amt;
680   End If;
681   If (p_rec.rqst_amt_uom = hr_api.g_varchar2) then
682     p_rec.rqst_amt_uom :=
683     ben_prc_shd.g_old_rec.rqst_amt_uom;
684   End If;
685   If (p_rec.rqst_btch_num = hr_api.g_number) then
686     p_rec.rqst_btch_num :=
687     ben_prc_shd.g_old_rec.rqst_btch_num;
688   End If;
689   If (p_rec.prtt_reimbmt_rqst_stat_cd = hr_api.g_varchar2) then
690     p_rec.prtt_reimbmt_rqst_stat_cd :=
691     ben_prc_shd.g_old_rec.prtt_reimbmt_rqst_stat_cd;
692   End If;
693   If (p_rec.reimbmt_ctfn_typ_prvdd_cd = hr_api.g_varchar2) then
694     p_rec.reimbmt_ctfn_typ_prvdd_cd :=
695     ben_prc_shd.g_old_rec.reimbmt_ctfn_typ_prvdd_cd;
696   End If;
697   If (p_rec.rcrrg_cd = hr_api.g_varchar2) then
698     p_rec.rcrrg_cd :=
699     ben_prc_shd.g_old_rec.rcrrg_cd;
700   End If;
701   If (p_rec.submitter_person_id = hr_api.g_number) then
702     p_rec.submitter_person_id :=
703     ben_prc_shd.g_old_rec.submitter_person_id;
704   End If;
705   If (p_rec.recipient_person_id = hr_api.g_number) then
706     p_rec.recipient_person_id :=
707     ben_prc_shd.g_old_rec.recipient_person_id;
708   End If;
709   If (p_rec.provider_person_id = hr_api.g_number) then
710     p_rec.provider_person_id :=
711     ben_prc_shd.g_old_rec.provider_person_id;
712   End If;
713   If (p_rec.provider_ssn_person_id = hr_api.g_number) then
714     p_rec.provider_ssn_person_id :=
715     ben_prc_shd.g_old_rec.provider_ssn_person_id;
716   End If;
717   If (p_rec.pl_id = hr_api.g_number) then
718     p_rec.pl_id :=
719     ben_prc_shd.g_old_rec.pl_id;
720   End If;
721   If (p_rec.gd_or_svc_typ_id = hr_api.g_number) then
722     p_rec.gd_or_svc_typ_id :=
723     ben_prc_shd.g_old_rec.gd_or_svc_typ_id;
724   End If;
725   If (p_rec.contact_relationship_id = hr_api.g_number) then
726     p_rec.contact_relationship_id :=
727     ben_prc_shd.g_old_rec.contact_relationship_id;
728   End If;
729   If (p_rec.business_group_id = hr_api.g_number) then
730     p_rec.business_group_id :=
731     ben_prc_shd.g_old_rec.business_group_id;
732   End If;
733   If (p_rec.opt_id = hr_api.g_number) then
734     p_rec.opt_id :=
735     ben_prc_shd.g_old_rec.opt_id;
736   End If;
737   If (p_rec.popl_yr_perd_id_1 = hr_api.g_number) then
738     p_rec.popl_yr_perd_id_1 :=
739     ben_prc_shd.g_old_rec.popl_yr_perd_id_1;
740   End If;
741   If (p_rec.popl_yr_perd_id_2 = hr_api.g_number) then
742     p_rec.popl_yr_perd_id_2 :=
743     ben_prc_shd.g_old_rec.popl_yr_perd_id_2;
744   End If;
745   If (p_rec.amt_year1 = hr_api.g_number) then
746     p_rec.amt_year1 :=
747     ben_prc_shd.g_old_rec.amt_year1;
748   End If;
749   If (p_rec.amt_year2 = hr_api.g_number) then
750     p_rec.amt_year2 :=
751     ben_prc_shd.g_old_rec.amt_year2;
752   End If;
753   If (p_rec.prc_attribute_category = hr_api.g_varchar2) then
754     p_rec.prc_attribute_category :=
755     ben_prc_shd.g_old_rec.prc_attribute_category;
756   End If;
757   If (p_rec.prc_attribute1 = hr_api.g_varchar2) then
758     p_rec.prc_attribute1 :=
759     ben_prc_shd.g_old_rec.prc_attribute1;
760   End If;
761   If (p_rec.prc_attribute2 = hr_api.g_varchar2) then
762     p_rec.prc_attribute2 :=
763     ben_prc_shd.g_old_rec.prc_attribute2;
764   End If;
765   If (p_rec.prc_attribute3 = hr_api.g_varchar2) then
766     p_rec.prc_attribute3 :=
767     ben_prc_shd.g_old_rec.prc_attribute3;
768   End If;
769   If (p_rec.prc_attribute4 = hr_api.g_varchar2) then
770     p_rec.prc_attribute4 :=
771     ben_prc_shd.g_old_rec.prc_attribute4;
772   End If;
773   If (p_rec.prc_attribute5 = hr_api.g_varchar2) then
774     p_rec.prc_attribute5 :=
775     ben_prc_shd.g_old_rec.prc_attribute5;
776   End If;
777   If (p_rec.prc_attribute6 = hr_api.g_varchar2) then
778     p_rec.prc_attribute6 :=
779     ben_prc_shd.g_old_rec.prc_attribute6;
780   End If;
781   If (p_rec.prc_attribute7 = hr_api.g_varchar2) then
782     p_rec.prc_attribute7 :=
783     ben_prc_shd.g_old_rec.prc_attribute7;
784   End If;
785   If (p_rec.prc_attribute8 = hr_api.g_varchar2) then
786     p_rec.prc_attribute8 :=
787     ben_prc_shd.g_old_rec.prc_attribute8;
788   End If;
789   If (p_rec.prc_attribute9 = hr_api.g_varchar2) then
790     p_rec.prc_attribute9 :=
791     ben_prc_shd.g_old_rec.prc_attribute9;
792   End If;
793   If (p_rec.prc_attribute10 = hr_api.g_varchar2) then
794     p_rec.prc_attribute10 :=
795     ben_prc_shd.g_old_rec.prc_attribute10;
796   End If;
797   If (p_rec.prc_attribute11 = hr_api.g_varchar2) then
798     p_rec.prc_attribute11 :=
799     ben_prc_shd.g_old_rec.prc_attribute11;
800   End If;
801   If (p_rec.prc_attribute12 = hr_api.g_varchar2) then
802     p_rec.prc_attribute12 :=
803     ben_prc_shd.g_old_rec.prc_attribute12;
804   End If;
805   If (p_rec.prc_attribute13 = hr_api.g_varchar2) then
806     p_rec.prc_attribute13 :=
807     ben_prc_shd.g_old_rec.prc_attribute13;
808   End If;
809   If (p_rec.prc_attribute14 = hr_api.g_varchar2) then
810     p_rec.prc_attribute14 :=
811     ben_prc_shd.g_old_rec.prc_attribute14;
812   End If;
813   If (p_rec.prc_attribute15 = hr_api.g_varchar2) then
814     p_rec.prc_attribute15 :=
815     ben_prc_shd.g_old_rec.prc_attribute15;
816   End If;
817   If (p_rec.prc_attribute16 = hr_api.g_varchar2) then
818     p_rec.prc_attribute16 :=
819     ben_prc_shd.g_old_rec.prc_attribute16;
820   End If;
821   If (p_rec.prc_attribute17 = hr_api.g_varchar2) then
822     p_rec.prc_attribute17 :=
823     ben_prc_shd.g_old_rec.prc_attribute17;
824   End If;
825   If (p_rec.prc_attribute18 = hr_api.g_varchar2) then
826     p_rec.prc_attribute18 :=
827     ben_prc_shd.g_old_rec.prc_attribute18;
828   End If;
829   If (p_rec.prc_attribute19 = hr_api.g_varchar2) then
830     p_rec.prc_attribute19 :=
831     ben_prc_shd.g_old_rec.prc_attribute19;
832   End If;
833   If (p_rec.prc_attribute20 = hr_api.g_varchar2) then
834     p_rec.prc_attribute20 :=
835     ben_prc_shd.g_old_rec.prc_attribute20;
836   End If;
837   If (p_rec.prc_attribute21 = hr_api.g_varchar2) then
838     p_rec.prc_attribute21 :=
839     ben_prc_shd.g_old_rec.prc_attribute21;
840   End If;
841   If (p_rec.prc_attribute22 = hr_api.g_varchar2) then
842     p_rec.prc_attribute22 :=
843     ben_prc_shd.g_old_rec.prc_attribute22;
844   End If;
845   If (p_rec.prc_attribute23 = hr_api.g_varchar2) then
846     p_rec.prc_attribute23 :=
847     ben_prc_shd.g_old_rec.prc_attribute23;
848   End If;
849   If (p_rec.prc_attribute24 = hr_api.g_varchar2) then
850     p_rec.prc_attribute24 :=
851     ben_prc_shd.g_old_rec.prc_attribute24;
852   End If;
853   If (p_rec.prc_attribute25 = hr_api.g_varchar2) then
854     p_rec.prc_attribute25 :=
855     ben_prc_shd.g_old_rec.prc_attribute25;
856   End If;
857   If (p_rec.prc_attribute26 = hr_api.g_varchar2) then
858     p_rec.prc_attribute26 :=
859     ben_prc_shd.g_old_rec.prc_attribute26;
860   End If;
861   If (p_rec.prc_attribute27 = hr_api.g_varchar2) then
862     p_rec.prc_attribute27 :=
863     ben_prc_shd.g_old_rec.prc_attribute27;
864   End If;
865   If (p_rec.prc_attribute28 = hr_api.g_varchar2) then
866     p_rec.prc_attribute28 :=
867     ben_prc_shd.g_old_rec.prc_attribute28;
868   End If;
869   If (p_rec.prc_attribute29 = hr_api.g_varchar2) then
870     p_rec.prc_attribute29 :=
871     ben_prc_shd.g_old_rec.prc_attribute29;
872   End If;
873   If (p_rec.prc_attribute30 = hr_api.g_varchar2) then
874     p_rec.prc_attribute30 :=
875     ben_prc_shd.g_old_rec.prc_attribute30;
876   End If;
877   If (p_rec.exp_incurd_dt = hr_api.g_date) then
878     p_rec.exp_incurd_dt :=
879     ben_prc_shd.g_old_rec.exp_incurd_dt;
880   End If;
881 
882   --
883   hr_utility.set_location(' Leaving:'||l_proc, 10);
884 --
885 End convert_defs;
886 --
887 -- ----------------------------------------------------------------------------
888 -- |---------------------------------< upd >----------------------------------|
889 -- ----------------------------------------------------------------------------
890 Procedure upd
891   (
892   p_rec			in out nocopy 	ben_prc_shd.g_rec_type,
893   p_effective_date	in 	date,
894   p_datetrack_mode	in 	varchar2
895   ) is
896 --
897   l_proc			varchar2(72) := g_package||'upd';
898   l_validation_start_date	date;
899   l_validation_end_date		date;
900 --
901 Begin
902   hr_utility.set_location('Entering:'||l_proc, 5);
903   --
904   -- Ensure that the DateTrack update mode is valid
905   --
906   dt_api.validate_dt_upd_mode(p_datetrack_mode => p_datetrack_mode);
907   --
908   -- We must lock the row which we need to update.
909   --
910   ben_prc_shd.lck
911 	(p_effective_date	 => p_effective_date,
912       	 p_datetrack_mode	 => p_datetrack_mode,
913       	 p_prtt_reimbmt_rqst_id	 => p_rec.prtt_reimbmt_rqst_id,
914       	 p_object_version_number => p_rec.object_version_number,
915       	 p_validation_start_date => l_validation_start_date,
916       	 p_validation_end_date	 => l_validation_end_date);
917   --
918   -- 1. During an update system defaults are used to determine if
919   --    arguments have been defaulted or not. We must therefore
920   --    derive the full record structure values to be updated.
921   --
922   -- 2. Call the supporting update validate operations.
923   --
924   convert_defs(p_rec);
925   ben_prc_bus.update_validate
926 	(p_rec			 => p_rec,
927 	 p_effective_date	 => p_effective_date,
928 	 p_datetrack_mode  	 => p_datetrack_mode,
929 	 p_validation_start_date => l_validation_start_date,
930 	 p_validation_end_date	 => l_validation_end_date);
931    hr_utility.set_location('after date  check ' || p_rec.prtt_reimbmt_rqst_stat_cd, 110);
932   --
933   -- Call the supporting pre-update operation
934   --
935   pre_update
936 	(p_rec			 => p_rec,
937 	 p_effective_date	 => p_effective_date,
938 	 p_datetrack_mode	 => p_datetrack_mode,
939 	 p_validation_start_date => l_validation_start_date,
940 	 p_validation_end_date	 => l_validation_end_date);
941   --
942   -- Update the row.
943   --
944   update_dml
945 	(p_rec			 => p_rec,
946 	 p_effective_date	 => p_effective_date,
947 	 p_datetrack_mode	 => p_datetrack_mode,
948 	 p_validation_start_date => l_validation_start_date,
949 	 p_validation_end_date	 => l_validation_end_date);
950   --
951   -- Call the supporting post-update operation
952   --
953   post_update
954 	(p_rec			 => p_rec,
955 	 p_effective_date	 => p_effective_date,
956 	 p_datetrack_mode	 => p_datetrack_mode,
957 	 p_validation_start_date => l_validation_start_date,
958 	 p_validation_end_date	 => l_validation_end_date);
959 End upd;
960 --
961 -- ----------------------------------------------------------------------------
962 -- |---------------------------------< upd >----------------------------------|
963 -- ----------------------------------------------------------------------------
964 Procedure upd
965   (
966   p_prtt_reimbmt_rqst_id         in number,
967   p_effective_start_date         out nocopy date,
968   p_effective_end_date           out nocopy date,
969   p_incrd_from_dt                in date             ,
970   p_incrd_to_dt                  in date             ,
971   p_rqst_num                     in number           ,
972   p_rqst_amt                     in number           ,
973   p_rqst_amt_uom                 in varchar2         ,
974   p_rqst_btch_num                in number           ,
975   p_prtt_reimbmt_rqst_stat_cd    in out nocopy varchar2     ,
976   p_reimbmt_ctfn_typ_prvdd_cd    in varchar2         ,
977   p_rcrrg_cd                     in varchar2         ,
978   p_submitter_person_id          in number           ,
979   p_recipient_person_id          in number           ,
980   p_provider_person_id           in number           ,
981   p_provider_ssn_person_id       in number           ,
982   p_pl_id                        in number           ,
983   p_gd_or_svc_typ_id             in number           ,
984   p_contact_relationship_id      in number           ,
985   p_business_group_id            in number           ,
986   p_opt_id                         in  number
987  ,p_popl_yr_perd_id_1              in  number
988  ,p_popl_yr_perd_id_2              in  number
989  ,p_amt_year1                      in  number
990  ,p_amt_year2                      in  number,
991   p_prc_attribute_category       in varchar2         ,
992   p_prc_attribute1               in varchar2         ,
993   p_prc_attribute2               in varchar2         ,
994   p_prc_attribute3               in varchar2         ,
995   p_prc_attribute4               in varchar2         ,
996   p_prc_attribute5               in varchar2         ,
997   p_prc_attribute6               in varchar2         ,
998   p_prc_attribute7               in varchar2         ,
999   p_prc_attribute8               in varchar2         ,
1000   p_prc_attribute9               in varchar2         ,
1001   p_prc_attribute10              in varchar2         ,
1002   p_prc_attribute11              in varchar2         ,
1003   p_prc_attribute12              in varchar2         ,
1004   p_prc_attribute13              in varchar2         ,
1005   p_prc_attribute14              in varchar2         ,
1006   p_prc_attribute15              in varchar2         ,
1007   p_prc_attribute16              in varchar2         ,
1008   p_prc_attribute17              in varchar2         ,
1009   p_prc_attribute18              in varchar2         ,
1010   p_prc_attribute19              in varchar2         ,
1011   p_prc_attribute20              in varchar2         ,
1012   p_prc_attribute21              in varchar2         ,
1013   p_prc_attribute22              in varchar2         ,
1014   p_prc_attribute23              in varchar2         ,
1015   p_prc_attribute24              in varchar2         ,
1016   p_prc_attribute25              in varchar2         ,
1017   p_prc_attribute26              in varchar2         ,
1018   p_prc_attribute27              in varchar2         ,
1019   p_prc_attribute28              in varchar2         ,
1020   p_prc_attribute29              in varchar2         ,
1021   p_prc_attribute30              in varchar2         ,
1022   p_prtt_enrt_rslt_id            in number           ,
1023   p_comment_id                   in number           ,
1024   p_object_version_number        in out nocopy number,
1025   -- Fide enh
1026   p_stat_rsn_cd                  in out nocopy varchar2  ,
1027   p_pymt_stat_cd                 in out nocopy varchar2  ,
1028   p_pymt_stat_rsn_cd             in out nocopy varchar2  ,
1029   p_stat_ovrdn_flag              in varchar2  ,
1030   p_stat_ovrdn_rsn_cd            in varchar2  ,
1031   p_stat_prr_to_ovrd             in varchar2  ,
1032   p_pymt_stat_ovrdn_flag         in varchar2  ,
1033   p_pymt_stat_ovrdn_rsn_cd       in varchar2  ,
1034   p_pymt_stat_prr_to_ovrd        in varchar2  ,
1035   p_adjmt_flag                   in varchar2  ,
1036   p_submtd_dt                    in date      ,
1037   p_ttl_rqst_amt                 in  number    ,
1038   p_aprvd_for_pymt_amt           in  out nocopy number  ,
1039   p_pymt_amount                  out nocopy number ,
1040   p_exp_incurd_dt		 in date      ,
1041   -- Fide enh
1042   p_effective_date		 in date,
1043   p_datetrack_mode		 in varchar2
1044   ) is
1045 --
1046   l_rec		ben_prc_shd.g_rec_type;
1047   l_proc	varchar2(72) := g_package||'upd';
1048 --
1049 Begin
1050   hr_utility.set_location('Entering:'||l_proc, 5);
1051   --
1052   -- Call conversion function to turn arguments into the
1053   -- l_rec structure.
1054   --
1055   l_rec :=
1056   ben_prc_shd.convert_args
1057   (
1058   p_prtt_reimbmt_rqst_id,
1059   null,
1060   null,
1061   p_incrd_from_dt,
1062   p_incrd_to_dt,
1063   p_rqst_num,
1064   p_rqst_amt,
1065   p_rqst_amt_uom,
1066   p_rqst_btch_num,
1067   p_prtt_reimbmt_rqst_stat_cd,
1068   p_reimbmt_ctfn_typ_prvdd_cd,
1069   p_rcrrg_cd,
1070   p_submitter_person_id,
1071   p_recipient_person_id,
1072   p_provider_person_id,
1073   p_provider_ssn_person_id,
1074   p_pl_id,
1075   p_gd_or_svc_typ_id,
1076   p_contact_relationship_id,
1077   p_business_group_id,
1078   p_opt_id,
1079   p_popl_yr_perd_id_1,
1080   p_popl_yr_perd_id_2,
1081   p_amt_year1,
1082   p_amt_year2 ,
1083   p_prc_attribute_category,
1084   p_prc_attribute1,
1085   p_prc_attribute2,
1086   p_prc_attribute3,
1087   p_prc_attribute4,
1088   p_prc_attribute5,
1089   p_prc_attribute6,
1090   p_prc_attribute7,
1091   p_prc_attribute8,
1092   p_prc_attribute9,
1093   p_prc_attribute10,
1094   p_prc_attribute11,
1095   p_prc_attribute12,
1096   p_prc_attribute13,
1097   p_prc_attribute14,
1098   p_prc_attribute15,
1099   p_prc_attribute16,
1100   p_prc_attribute17,
1101   p_prc_attribute18,
1102   p_prc_attribute19,
1103   p_prc_attribute20,
1104   p_prc_attribute21,
1105   p_prc_attribute22,
1106   p_prc_attribute23,
1107   p_prc_attribute24,
1108   p_prc_attribute25,
1109   p_prc_attribute26,
1110   p_prc_attribute27,
1111   p_prc_attribute28,
1112   p_prc_attribute29,
1113   p_prc_attribute30,
1114   p_prtt_enrt_rslt_id,
1115   p_comment_id       ,
1116   p_object_version_number ,
1117   p_stat_rsn_cd,
1118   p_pymt_stat_cd,
1119   p_pymt_stat_rsn_cd,
1120   p_stat_ovrdn_flag,
1121   p_stat_ovrdn_rsn_cd,
1122   p_stat_prr_to_ovrd,
1123   p_pymt_stat_ovrdn_flag,
1124   p_pymt_stat_ovrdn_rsn_cd,
1125   p_pymt_stat_prr_to_ovrd,
1126   p_adjmt_flag,
1127   p_submtd_dt,
1128   p_ttl_rqst_amt,
1129   p_aprvd_for_pymt_amt,
1130   null ,
1131   p_exp_incurd_dt
1132   );
1133   --
1134   -- Having converted the arguments into the
1135   -- plsql record structure we call the corresponding record
1136   -- business process.
1137   --
1138   upd(l_rec, p_effective_date, p_datetrack_mode);
1139 
1140   p_object_version_number       := l_rec.object_version_number;
1141   p_effective_start_date        := l_rec.effective_start_date;
1142   p_effective_end_date          := l_rec.effective_end_date;
1143   p_prtt_reimbmt_rqst_Stat_cd   := l_rec.prtt_reimbmt_rqst_Stat_cd;
1144   p_stat_rsn_cd                 := l_rec.stat_rsn_cd ;
1145   p_pymt_stat_rsn_cd            := l_rec.pymt_stat_rsn_cd;
1146   p_pymt_stat_cd                := l_rec.pymt_stat_cd ;
1147   p_pymt_amount                 := l_rec.pymt_amount ;
1148   p_aprvd_for_pymt_amt          := l_rec.aprvd_for_pymt_amt ;
1149   --
1150   --
1151   hr_utility.set_location(' Leaving:'||l_proc, 10);
1152 End upd;
1153 --
1154 end ben_prc_upd;