DBA Data[Home] [Help]

PACKAGE BODY: APPS.PAY_PMA_UPD

Source


1 Package Body pay_pma_upd as
2 /* $Header: pypmarhi.pkb 115.2 2002/12/11 11:12:57 ssivasu2 noship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- |                     Private Global Definitions                           |
6 -- ----------------------------------------------------------------------------
7 --
8 g_package  varchar2(33)	:= '  pay_pma_upd.';  -- Global package name
9 --
10 -- ----------------------------------------------------------------------------
11 -- |------------------------------< update_dml >------------------------------|
12 -- ----------------------------------------------------------------------------
13 -- {Start Of Comments}
14 --
15 -- Description:
16 --   This procedure controls the actual dml update logic. The processing of
17 --   this procedure is:
18 --   1) Increment the object_version_number by 1 if the object_version_number
19 --      is defined as an attribute for this entity.
20 --   2) To set and unset the g_api_dml status as required (as we are about to
21 --      perform dml).
22 --   3) To update the specified row in the schema using the primary key in
23 --      the predicates.
24 --   4) To trap any constraint violations that may have occurred.
25 --   5) To raise any other errors.
26 --
27 -- Prerequisites:
28 --   This is an internal private procedure which must be called from the upd
29 --   procedure.
30 --
31 -- In Parameters:
32 --   A Pl/Sql record structre.
33 --
34 -- Post Success:
35 --   The specified row will be updated in the schema.
36 --
37 -- Post Failure:
38 --   On the update dml failure it is important to note that we always reset the
39 --   g_api_dml status to false.
40 --   If a check, unique or parent integrity constraint violation is raised the
41 --   constraint_error procedure will be called.
42 --   If any other error is reported, the error will be raised after the
43 --   g_api_dml status is reset.
44 --
45 -- Developer Implementation Notes:
46 --   The update 'set' attribute list should be modified if any of your
47 --   attributes are not updateable.
48 --
49 -- Access Status:
50 --   Internal Row Handler Use Only.
51 --
52 -- {End Of Comments}
53 -- ----------------------------------------------------------------------------
54 Procedure update_dml(p_rec in out nocopy pay_pma_shd.g_rec_type) is
55 --
56   l_proc  varchar2(72) := g_package||'update_dml';
57 --
58 Begin
59   hr_utility.set_location('Entering:'||l_proc, 5);
60   --
61   -- Increment the object version
62   --
63   p_rec.object_version_number := p_rec.object_version_number + 1;
64   --
65   pay_pma_shd.g_api_dml := true;  -- Set the api dml status
66   --
67   -- Update the pay_ca_pmed_accounts Row
68   --
69   update pay_ca_pmed_accounts
70   set
71   organization_id                   = p_rec.organization_id,
72   source_id                         = p_rec.source_id,
73   account_number                    = p_rec.account_number,
74   enabled                           = p_rec.enabled,
75   description                       = p_rec.description,
76   business_group_id                 = p_rec.business_group_id,
77   attribute_category                = p_rec.attribute_category,
78   attribute1                        = p_rec.attribute1,
79   attribute2                        = p_rec.attribute2,
80   attribute3                        = p_rec.attribute3,
81   attribute4                        = p_rec.attribute4,
82   attribute5                        = p_rec.attribute5,
83   attribute6                        = p_rec.attribute6,
84   attribute7                        = p_rec.attribute7,
85   attribute8                        = p_rec.attribute8,
86   attribute9                        = p_rec.attribute9,
87   attribute10                       = p_rec.attribute10,
88   attribute11                       = p_rec.attribute11,
89   attribute12                       = p_rec.attribute12,
90   attribute13                       = p_rec.attribute13,
91   attribute14                       = p_rec.attribute14,
92   attribute15                       = p_rec.attribute15,
93   attribute16                       = p_rec.attribute16,
94   attribute17                       = p_rec.attribute17,
95   attribute18                       = p_rec.attribute18,
96   attribute19                       = p_rec.attribute19,
97   attribute20                       = p_rec.attribute20,
98   attribute21                       = p_rec.attribute21,
99   attribute22                       = p_rec.attribute22,
100   attribute23                       = p_rec.attribute23,
101   attribute24                       = p_rec.attribute24,
102   attribute25                       = p_rec.attribute25,
103   attribute26                       = p_rec.attribute26,
104   attribute27                       = p_rec.attribute27,
105   attribute28                       = p_rec.attribute28,
106   attribute29                       = p_rec.attribute29,
107   attribute30                       = p_rec.attribute30,
108   object_version_number             = p_rec.object_version_number
109   where source_id = p_rec.source_id;
110   --
111   pay_pma_shd.g_api_dml := false;   -- Unset the api dml status
112   --
113   hr_utility.set_location(' Leaving:'||l_proc, 10);
114 --
115 Exception
116   When hr_api.check_integrity_violated Then
117     -- A check constraint has been violated
118     pay_pma_shd.g_api_dml := false;   -- Unset the api dml status
119     pay_pma_shd.constraint_error
120       (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
121   When hr_api.parent_integrity_violated Then
122     -- Parent integrity has been violated
123     pay_pma_shd.g_api_dml := false;   -- Unset the api dml status
124     pay_pma_shd.constraint_error
125       (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
126   When hr_api.unique_integrity_violated Then
127     -- Unique integrity has been violated
128     pay_pma_shd.g_api_dml := false;   -- Unset the api dml status
129     pay_pma_shd.constraint_error
130       (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
131   When Others Then
132     pay_pma_shd.g_api_dml := false;   -- Unset the api dml status
133     Raise;
134 End update_dml;
135 --
136 -- ----------------------------------------------------------------------------
137 -- |------------------------------< pre_update >------------------------------|
138 -- ----------------------------------------------------------------------------
139 -- {Start Of Comments}
140 --
141 -- Description:
142 --   This private procedure contains any processing which is required before
143 --   the update dml.
144 --
145 -- Prerequisites:
146 --   This is an internal procedure which is called from the upd procedure.
147 --
148 -- In Parameters:
149 --   A Pl/Sql record structre.
150 --
151 -- Post Success:
152 --   Processing continues.
153 --
154 -- Post Failure:
155 --   If an error has occurred, an error message and exception will be raised
156 --   but not handled.
157 --
158 -- Developer Implementation Notes:
159 --   Any pre-processing required before the update dml is issued should be
160 --   coded within this procedure. It is important to note that any 3rd party
161 --   maintenance should be reviewed before placing in this procedure.
162 --
163 -- Access Status:
164 --   Internal Row Handler Use Only.
165 --
166 -- {End Of Comments}
167 -- ----------------------------------------------------------------------------
168 Procedure pre_update(p_rec in pay_pma_shd.g_rec_type) is
169 --
170   l_proc  varchar2(72) := g_package||'pre_update';
171 --
172 Begin
173   hr_utility.set_location('Entering:'||l_proc, 5);
174   --
175   hr_utility.set_location(' Leaving:'||l_proc, 10);
176 End pre_update;
177 --
178 -- ----------------------------------------------------------------------------
179 -- |-----------------------------< post_update >------------------------------|
180 -- ----------------------------------------------------------------------------
181 -- {Start Of Comments}
182 --
183 -- Description:
184 --   This private procedure contains any processing which is required after the
185 --   update dml.
186 --
187 -- Prerequisites:
188 --   This is an internal procedure which is called from the upd procedure.
189 --
190 -- In Parameters:
191 --   A Pl/Sql record structre.
192 --
193 -- Post Success:
194 --   Processing continues.
195 --
196 -- Post Failure:
197 --   If an error has occurred, an error message and exception will be raised
198 --   but not handled.
199 --
200 -- Developer Implementation Notes:
201 --   Any post-processing required after the update dml is issued should be
202 --   coded within this procedure. It is important to note that any 3rd party
203 --   maintenance should be reviewed before placing in this procedure.
204 --
205 -- Access Status:
206 --   Internal Row Handler Use Only.
207 --
208 -- {End Of Comments}
209 -- ----------------------------------------------------------------------------
210 Procedure post_update(p_rec in pay_pma_shd.g_rec_type) is
211 --
212   l_proc  varchar2(72) := g_package||'post_update';
213 --
214 Begin
215   hr_utility.set_location('Entering:'||l_proc, 5);
216 --
217   --
218   -- Start of API User Hook for post_update.
219   --
220   begin
221     --
222     pay_pma_rku.after_update
223       (
224   p_organization_id               =>p_rec.organization_id
225  ,p_source_id                     =>p_rec.source_id
226  ,p_account_number                =>p_rec.account_number
227  ,p_enabled                       =>p_rec.enabled
228  ,p_description                   =>p_rec.description
229  ,p_business_group_id             =>p_rec.business_group_id
230  ,p_attribute_category            =>p_rec.attribute_category
231  ,p_attribute1                    =>p_rec.attribute1
232  ,p_attribute2                    =>p_rec.attribute2
233  ,p_attribute3                    =>p_rec.attribute3
234  ,p_attribute4                    =>p_rec.attribute4
235  ,p_attribute5                    =>p_rec.attribute5
236  ,p_attribute6                    =>p_rec.attribute6
237  ,p_attribute7                    =>p_rec.attribute7
238  ,p_attribute8                    =>p_rec.attribute8
239  ,p_attribute9                    =>p_rec.attribute9
240  ,p_attribute10                   =>p_rec.attribute10
241  ,p_attribute11                   =>p_rec.attribute11
242  ,p_attribute12                   =>p_rec.attribute12
243  ,p_attribute13                   =>p_rec.attribute13
244  ,p_attribute14                   =>p_rec.attribute14
245  ,p_attribute15                   =>p_rec.attribute15
246  ,p_attribute16                   =>p_rec.attribute16
247  ,p_attribute17                   =>p_rec.attribute17
248  ,p_attribute18                   =>p_rec.attribute18
249  ,p_attribute19                   =>p_rec.attribute19
250  ,p_attribute20                   =>p_rec.attribute20
251  ,p_attribute21                   =>p_rec.attribute21
252  ,p_attribute22                   =>p_rec.attribute22
253  ,p_attribute23                   =>p_rec.attribute23
254  ,p_attribute24                   =>p_rec.attribute24
255  ,p_attribute25                   =>p_rec.attribute25
256  ,p_attribute26                   =>p_rec.attribute26
257  ,p_attribute27                   =>p_rec.attribute27
258  ,p_attribute28                   =>p_rec.attribute28
259  ,p_attribute29                   =>p_rec.attribute29
260  ,p_attribute30                   =>p_rec.attribute30
261  ,p_object_version_number         =>p_rec.object_version_number
262  ,p_organization_id_o             =>pay_pma_shd.g_old_rec.organization_id
263  ,p_account_number_o              =>pay_pma_shd.g_old_rec.account_number
264  ,p_enabled_o                     =>pay_pma_shd.g_old_rec.enabled
265  ,p_description_o                 =>pay_pma_shd.g_old_rec.description
266  ,p_business_group_id_o           =>pay_pma_shd.g_old_rec.business_group_id
267  ,p_attribute_category_o          =>pay_pma_shd.g_old_rec.attribute_category
268  ,p_attribute1_o                  =>pay_pma_shd.g_old_rec.attribute1
269  ,p_attribute2_o                  =>pay_pma_shd.g_old_rec.attribute2
270  ,p_attribute3_o                  =>pay_pma_shd.g_old_rec.attribute3
271  ,p_attribute4_o                  =>pay_pma_shd.g_old_rec.attribute4
272  ,p_attribute5_o                  =>pay_pma_shd.g_old_rec.attribute5
273  ,p_attribute6_o                  =>pay_pma_shd.g_old_rec.attribute6
274  ,p_attribute7_o                  =>pay_pma_shd.g_old_rec.attribute7
275  ,p_attribute8_o                  =>pay_pma_shd.g_old_rec.attribute8
276  ,p_attribute9_o                  =>pay_pma_shd.g_old_rec.attribute9
277  ,p_attribute10_o                 =>pay_pma_shd.g_old_rec.attribute10
278  ,p_attribute11_o                 =>pay_pma_shd.g_old_rec.attribute11
279  ,p_attribute12_o                 =>pay_pma_shd.g_old_rec.attribute12
280  ,p_attribute13_o                 =>pay_pma_shd.g_old_rec.attribute13
281  ,p_attribute14_o                 =>pay_pma_shd.g_old_rec.attribute14
282  ,p_attribute15_o                 =>pay_pma_shd.g_old_rec.attribute15
283  ,p_attribute16_o                 =>pay_pma_shd.g_old_rec.attribute16
284  ,p_attribute17_o                 =>pay_pma_shd.g_old_rec.attribute17
285  ,p_attribute18_o                 =>pay_pma_shd.g_old_rec.attribute18
286  ,p_attribute19_o                 =>pay_pma_shd.g_old_rec.attribute19
287  ,p_attribute20_o                 =>pay_pma_shd.g_old_rec.attribute20
288  ,p_attribute21_o                 =>pay_pma_shd.g_old_rec.attribute21
289  ,p_attribute22_o                 =>pay_pma_shd.g_old_rec.attribute22
290  ,p_attribute23_o                 =>pay_pma_shd.g_old_rec.attribute23
291  ,p_attribute24_o                 =>pay_pma_shd.g_old_rec.attribute24
292  ,p_attribute25_o                 =>pay_pma_shd.g_old_rec.attribute25
293  ,p_attribute26_o                 =>pay_pma_shd.g_old_rec.attribute26
294  ,p_attribute27_o                 =>pay_pma_shd.g_old_rec.attribute27
295  ,p_attribute28_o                 =>pay_pma_shd.g_old_rec.attribute28
296  ,p_attribute29_o                 =>pay_pma_shd.g_old_rec.attribute29
297  ,p_attribute30_o                 =>pay_pma_shd.g_old_rec.attribute30
298  ,p_object_version_number_o       =>pay_pma_shd.g_old_rec.object_version_number
299       );
300     --
301   exception
302     --
303     when hr_api.cannot_find_prog_unit then
304       --
305       hr_api.cannot_find_prog_unit_error
306         (p_module_name => 'pay_ca_pmed_accounts'
307         ,p_hook_type   => 'AU');
308       --
309   end;
310   --
311   -- End of API User Hook for post_update.
312   --
313   --
314   hr_utility.set_location(' Leaving:'||l_proc, 10);
315 End post_update;
316 --
317 -- ----------------------------------------------------------------------------
318 -- |-----------------------------< convert_defs >-----------------------------|
319 -- ----------------------------------------------------------------------------
320 -- {Start Of Comments}
321 --
322 -- Description:
323 --   The Convert_Defs procedure has one very important function:
324 --   It must return the record structure for the row with all system defaulted
325 --   values converted into its corresponding parameter value for update. When
326 --   we attempt to update a row through the Upd process , certain
327 --   parameters can be defaulted which enables flexibility in the calling of
328 --   the upd process (e.g. only attributes which need to be updated need to be
329 --   specified). For the upd process to determine which attributes
330 --   have NOT been specified we need to check if the parameter has a reserved
331 --   system default value. Therefore, for all parameters which have a
332 --   corresponding reserved system default mechanism specified we need to
333 --   check if a system default is being used. If a system default is being
334 --   used then we convert the defaulted value into its corresponding attribute
335 --   value held in the g_old_rec data structure.
336 --
337 -- Prerequisites:
338 --   This private function can only be called from the upd process.
339 --
340 -- In Parameters:
341 --   A Pl/Sql record structre.
342 --
343 -- Post Success:
344 --   The record structure will be returned with all system defaulted parameter
345 --   values converted into its current row attribute value.
346 --
347 -- Post Failure:
348 --   No direct error handling is required within this function. Any possible
349 --   errors within this procedure will be a PL/SQL value error due to conversion
350 --   of datatypes or data lengths.
351 --
352 -- Developer Implementation Notes:
353 --   None.
354 --
355 -- Access Status:
356 --   Internal Row Handler Use Only.
357 --
358 -- {End Of Comments}
359 -- ----------------------------------------------------------------------------
360 Procedure convert_defs(p_rec in out nocopy pay_pma_shd.g_rec_type) is
361 --
362   l_proc  varchar2(72) := g_package||'convert_defs';
363 --
364 Begin
365   --
366   hr_utility.set_location('Entering:'||l_proc, 5);
367   --
368   -- We must now examine each argument value in the
369   -- p_rec plsql record structure
370   -- to see if a system default is being used. If a system default
371   -- is being used then we must set to the 'current' argument value.
372   --
373   If (p_rec.organization_id = hr_api.g_number) then
374     p_rec.organization_id :=
375     pay_pma_shd.g_old_rec.organization_id;
376   End If;
377   If (p_rec.account_number = hr_api.g_varchar2) then
378     p_rec.account_number :=
379     pay_pma_shd.g_old_rec.account_number;
380   End If;
381   If (p_rec.enabled = hr_api.g_varchar2) then
382     p_rec.enabled :=
383     pay_pma_shd.g_old_rec.enabled;
384   End If;
385   If (p_rec.description = hr_api.g_varchar2) then
386     p_rec.description :=
387     pay_pma_shd.g_old_rec.description;
388   End If;
389   If (p_rec.business_group_id = hr_api.g_number) then
390     p_rec.business_group_id :=
391     pay_pma_shd.g_old_rec.business_group_id;
392   End If;
393   If (p_rec.attribute_category = hr_api.g_varchar2) then
394     p_rec.attribute_category :=
395     pay_pma_shd.g_old_rec.attribute_category;
396   End If;
397   If (p_rec.attribute1 = hr_api.g_varchar2) then
398     p_rec.attribute1 :=
399     pay_pma_shd.g_old_rec.attribute1;
400   End If;
401   If (p_rec.attribute2 = hr_api.g_varchar2) then
402     p_rec.attribute2 :=
403     pay_pma_shd.g_old_rec.attribute2;
404   End If;
405   If (p_rec.attribute3 = hr_api.g_varchar2) then
406     p_rec.attribute3 :=
407     pay_pma_shd.g_old_rec.attribute3;
408   End If;
409   If (p_rec.attribute4 = hr_api.g_varchar2) then
410     p_rec.attribute4 :=
411     pay_pma_shd.g_old_rec.attribute4;
412   End If;
413   If (p_rec.attribute5 = hr_api.g_varchar2) then
414     p_rec.attribute5 :=
415     pay_pma_shd.g_old_rec.attribute5;
416   End If;
417   If (p_rec.attribute6 = hr_api.g_varchar2) then
418     p_rec.attribute6 :=
419     pay_pma_shd.g_old_rec.attribute6;
420   End If;
421   If (p_rec.attribute7 = hr_api.g_varchar2) then
422     p_rec.attribute7 :=
423     pay_pma_shd.g_old_rec.attribute7;
424   End If;
425   If (p_rec.attribute8 = hr_api.g_varchar2) then
426     p_rec.attribute8 :=
427     pay_pma_shd.g_old_rec.attribute8;
428   End If;
429   If (p_rec.attribute9 = hr_api.g_varchar2) then
430     p_rec.attribute9 :=
431     pay_pma_shd.g_old_rec.attribute9;
432   End If;
433   If (p_rec.attribute10 = hr_api.g_varchar2) then
434     p_rec.attribute10 :=
435     pay_pma_shd.g_old_rec.attribute10;
436   End If;
437   If (p_rec.attribute11 = hr_api.g_varchar2) then
438     p_rec.attribute11 :=
439     pay_pma_shd.g_old_rec.attribute11;
440   End If;
441   If (p_rec.attribute12 = hr_api.g_varchar2) then
442     p_rec.attribute12 :=
443     pay_pma_shd.g_old_rec.attribute12;
444   End If;
445   If (p_rec.attribute13 = hr_api.g_varchar2) then
446     p_rec.attribute13 :=
447     pay_pma_shd.g_old_rec.attribute13;
448   End If;
449   If (p_rec.attribute14 = hr_api.g_varchar2) then
450     p_rec.attribute14 :=
451     pay_pma_shd.g_old_rec.attribute14;
452   End If;
453   If (p_rec.attribute15 = hr_api.g_varchar2) then
454     p_rec.attribute15 :=
455     pay_pma_shd.g_old_rec.attribute15;
456   End If;
457   If (p_rec.attribute16 = hr_api.g_varchar2) then
458     p_rec.attribute16 :=
459     pay_pma_shd.g_old_rec.attribute16;
460   End If;
461   If (p_rec.attribute17 = hr_api.g_varchar2) then
462     p_rec.attribute17 :=
463     pay_pma_shd.g_old_rec.attribute17;
464   End If;
465   If (p_rec.attribute18 = hr_api.g_varchar2) then
466     p_rec.attribute18 :=
467     pay_pma_shd.g_old_rec.attribute18;
468   End If;
469   If (p_rec.attribute19 = hr_api.g_varchar2) then
470     p_rec.attribute19 :=
471     pay_pma_shd.g_old_rec.attribute19;
472   End If;
473   If (p_rec.attribute20 = hr_api.g_varchar2) then
474     p_rec.attribute20 :=
475     pay_pma_shd.g_old_rec.attribute20;
476   End If;
477   If (p_rec.attribute21 = hr_api.g_varchar2) then
478     p_rec.attribute21 :=
479     pay_pma_shd.g_old_rec.attribute21;
480   End If;
481   If (p_rec.attribute22 = hr_api.g_varchar2) then
482     p_rec.attribute22 :=
483     pay_pma_shd.g_old_rec.attribute22;
484   End If;
485   If (p_rec.attribute23 = hr_api.g_varchar2) then
486     p_rec.attribute23 :=
487     pay_pma_shd.g_old_rec.attribute23;
488   End If;
489   If (p_rec.attribute24 = hr_api.g_varchar2) then
490     p_rec.attribute24 :=
491     pay_pma_shd.g_old_rec.attribute24;
492   End If;
493   If (p_rec.attribute25 = hr_api.g_varchar2) then
494     p_rec.attribute25 :=
495     pay_pma_shd.g_old_rec.attribute25;
496   End If;
497   If (p_rec.attribute26 = hr_api.g_varchar2) then
498     p_rec.attribute26 :=
499     pay_pma_shd.g_old_rec.attribute26;
500   End If;
501   If (p_rec.attribute27 = hr_api.g_varchar2) then
502     p_rec.attribute27 :=
503     pay_pma_shd.g_old_rec.attribute27;
504   End If;
505   If (p_rec.attribute28 = hr_api.g_varchar2) then
506     p_rec.attribute28 :=
507     pay_pma_shd.g_old_rec.attribute28;
508   End If;
509   If (p_rec.attribute29 = hr_api.g_varchar2) then
510     p_rec.attribute29 :=
511     pay_pma_shd.g_old_rec.attribute29;
512   End If;
513   If (p_rec.attribute30 = hr_api.g_varchar2) then
514     p_rec.attribute30 :=
515     pay_pma_shd.g_old_rec.attribute30;
516   End If;
517 
518   --
519   hr_utility.set_location(' Leaving:'||l_proc, 10);
520 --
521 End convert_defs;
522 --
523 -- ----------------------------------------------------------------------------
524 -- |---------------------------------< upd >----------------------------------|
525 -- ----------------------------------------------------------------------------
526 Procedure upd
527   (
528   p_rec        in out nocopy pay_pma_shd.g_rec_type
529   ) is
530 --
531   l_proc  varchar2(72) := g_package||'upd';
532 --
533 Begin
534   hr_utility.set_location('Entering:'||l_proc, 5);
535   --
536   -- We must lock the row which we need to update.
537   --
538   pay_pma_shd.lck
539 	(
540 	p_rec.source_id,
541 	p_rec.object_version_number
542 	);
543   --
544   -- 1. During an update system defaults are used to determine if
545   --    arguments have been defaulted or not. We must therefore
546   --    derive the full record structure values to be updated.
547   --
548   -- 2. Call the supporting update validate operations.
549   --
550   convert_defs(p_rec);
551   pay_pma_bus.update_validate(p_rec);
552   --
553   -- Call the supporting pre-update operation
554   --
555   pre_update(p_rec);
556   --
557   -- Update the row.
558   --
559   update_dml(p_rec);
560   --
561   -- Call the supporting post-update operation
562   --
563   post_update(p_rec);
564 End upd;
565 --
566 -- ----------------------------------------------------------------------------
567 -- |---------------------------------< upd >----------------------------------|
568 -- ----------------------------------------------------------------------------
569 Procedure upd
570   (
571   p_organization_id              in number           default hr_api.g_number,
572   p_source_id                    in number,
573   p_account_number               in varchar2         default hr_api.g_varchar2,
574   p_enabled                      in varchar2         default hr_api.g_varchar2,
575   p_description                  in varchar2         default hr_api.g_varchar2,
576   p_business_group_id            in number           default hr_api.g_number,
577   p_attribute_category           in varchar2         default hr_api.g_varchar2,
578   p_attribute1                   in varchar2         default hr_api.g_varchar2,
579   p_attribute2                   in varchar2         default hr_api.g_varchar2,
580   p_attribute3                   in varchar2         default hr_api.g_varchar2,
581   p_attribute4                   in varchar2         default hr_api.g_varchar2,
582   p_attribute5                   in varchar2         default hr_api.g_varchar2,
583   p_attribute6                   in varchar2         default hr_api.g_varchar2,
584   p_attribute7                   in varchar2         default hr_api.g_varchar2,
585   p_attribute8                   in varchar2         default hr_api.g_varchar2,
586   p_attribute9                   in varchar2         default hr_api.g_varchar2,
587   p_attribute10                  in varchar2         default hr_api.g_varchar2,
588   p_attribute11                  in varchar2         default hr_api.g_varchar2,
589   p_attribute12                  in varchar2         default hr_api.g_varchar2,
590   p_attribute13                  in varchar2         default hr_api.g_varchar2,
591   p_attribute14                  in varchar2         default hr_api.g_varchar2,
592   p_attribute15                  in varchar2         default hr_api.g_varchar2,
593   p_attribute16                  in varchar2         default hr_api.g_varchar2,
594   p_attribute17                  in varchar2         default hr_api.g_varchar2,
595   p_attribute18                  in varchar2         default hr_api.g_varchar2,
596   p_attribute19                  in varchar2         default hr_api.g_varchar2,
597   p_attribute20                  in varchar2         default hr_api.g_varchar2,
598   p_attribute21                  in varchar2         default hr_api.g_varchar2,
599   p_attribute22                  in varchar2         default hr_api.g_varchar2,
600   p_attribute23                  in varchar2         default hr_api.g_varchar2,
601   p_attribute24                  in varchar2         default hr_api.g_varchar2,
602   p_attribute25                  in varchar2         default hr_api.g_varchar2,
603   p_attribute26                  in varchar2         default hr_api.g_varchar2,
604   p_attribute27                  in varchar2         default hr_api.g_varchar2,
605   p_attribute28                  in varchar2         default hr_api.g_varchar2,
606   p_attribute29                  in varchar2         default hr_api.g_varchar2,
607   p_attribute30                  in varchar2         default hr_api.g_varchar2,
608   p_object_version_number        in out nocopy       number
609   ) is
610 --
611   l_rec	  pay_pma_shd.g_rec_type;
612   l_proc  varchar2(72) := g_package||'upd';
613 --
614 Begin
615   hr_utility.set_location('Entering:'||l_proc, 5);
616   --
617   -- Call conversion function to turn arguments into the
618   -- l_rec structure.
619   --
620   l_rec :=
621   pay_pma_shd.convert_args
622   (
623   p_organization_id,
624   p_source_id,
625   p_account_number,
626   p_enabled,
627   p_description,
628   p_business_group_id,
629   p_attribute_category,
630   p_attribute1,
631   p_attribute2,
632   p_attribute3,
633   p_attribute4,
634   p_attribute5,
635   p_attribute6,
636   p_attribute7,
637   p_attribute8,
638   p_attribute9,
639   p_attribute10,
640   p_attribute11,
641   p_attribute12,
642   p_attribute13,
643   p_attribute14,
644   p_attribute15,
645   p_attribute16,
646   p_attribute17,
647   p_attribute18,
648   p_attribute19,
649   p_attribute20,
650   p_attribute21,
651   p_attribute22,
652   p_attribute23,
653   p_attribute24,
654   p_attribute25,
655   p_attribute26,
656   p_attribute27,
657   p_attribute28,
658   p_attribute29,
659   p_attribute30,
660   p_object_version_number
661   );
662   --
663   -- Having converted the arguments into the
664   -- plsql record structure we call the corresponding record
665   -- business process.
666   --
667   upd(l_rec);
668   p_object_version_number := l_rec.object_version_number;
669   --
670   hr_utility.set_location(' Leaving:'||l_proc, 10);
671 End upd;
672 --
673 end pay_pma_upd;