DBA Data[Home] [Help]

PACKAGE BODY: APPS.PAY_STA_UPD

Source


1 Package Body pay_sta_upd as
2 /* $Header: pystarhi.pkb 120.2.12020000.2 2012/07/05 02:46:41 amnaraya ship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- |                     Private Global Definitions                           |
6 -- ----------------------------------------------------------------------------
7 --
8 g_package  varchar2(33) := '  pay_sta_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 insert 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 pay_sta_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      => 'pay_us_emp_state_tax_rules_f',
78          p_base_key_column      => 'emp_state_tax_rule_id',
79          p_base_key_value      => p_rec.emp_state_tax_rule_id);
80     --
81     pay_sta_shd.g_api_dml := true;  -- Set the api dml status
82     --
83     -- Update the pay_us_emp_state_tax_rules_f Row
84     --
85     update  pay_us_emp_state_tax_rules_f
86     set
87         emp_state_tax_rule_id           = p_rec.emp_state_tax_rule_id,
88     assignment_id                   = p_rec.assignment_id,
89     state_code                      = p_rec.state_code,
90     jurisdiction_code               = p_rec.jurisdiction_code,
91     business_group_id               = p_rec.business_group_id,
92     additional_wa_amount            = p_rec.additional_wa_amount,
93     filing_status_code              = p_rec.filing_status_code,
94     remainder_percent               = p_rec.remainder_percent,
95     secondary_wa                    = p_rec.secondary_wa,
96     sit_additional_tax              = p_rec.sit_additional_tax,
97     sit_override_amount             = p_rec.sit_override_amount,
98     sit_override_rate               = p_rec.sit_override_rate,
99     withholding_allowances          = p_rec.withholding_allowances,
100     excessive_wa_reject_date        = p_rec.excessive_wa_reject_date,
101     sdi_exempt                      = p_rec.sdi_exempt,
102     sit_exempt                      = p_rec.sit_exempt,
103     sit_optional_calc_ind           = p_rec.sit_optional_calc_ind,
104     state_non_resident_cert         = p_rec.state_non_resident_cert,
105     sui_exempt                      = p_rec.sui_exempt,
106     wc_exempt                       = p_rec.wc_exempt,
107     wage_exempt                     = p_rec.wage_exempt,
108     sui_wage_base_override_amount   = p_rec.sui_wage_base_override_amount,
109     supp_tax_override_rate          = p_rec.supp_tax_override_rate,
110     object_version_number           = p_rec.object_version_number,
111     attribute_category              = p_rec.attribute_category,
112     attribute1                      = p_rec.attribute1,
113     attribute2                      = p_rec.attribute2,
114     attribute3                      = p_rec.attribute3,
115     attribute4                      = p_rec.attribute4,
116     attribute5                      = p_rec.attribute5,
117     attribute6                      = p_rec.attribute6,
118     attribute7                      = p_rec.attribute7,
119     attribute8                      = p_rec.attribute8,
120     attribute9                      = p_rec.attribute9,
121     attribute10                     = p_rec.attribute10,
122     attribute11                     = p_rec.attribute11,
123     attribute12                     = p_rec.attribute12,
124     attribute13                     = p_rec.attribute13,
125     attribute14                     = p_rec.attribute14,
126     attribute15                     = p_rec.attribute15,
127     attribute16                     = p_rec.attribute16,
128     attribute17                     = p_rec.attribute17,
129     attribute18                     = p_rec.attribute18,
130     attribute19                     = p_rec.attribute19,
131     attribute20                     = p_rec.attribute20,
132     attribute21                     = p_rec.attribute21,
133     attribute22                     = p_rec.attribute22,
134     attribute23                     = p_rec.attribute23,
135     attribute24                     = p_rec.attribute24,
136     attribute25                     = p_rec.attribute25,
137     attribute26                     = p_rec.attribute26,
138     attribute27                     = p_rec.attribute27,
139     attribute28                     = p_rec.attribute28,
140     attribute29                     = p_rec.attribute29,
141     attribute30                     = p_rec.attribute30,
142     sta_information_category        = p_rec.sta_information_category,
143     sta_information1                      = p_rec.sta_information1,
144     sta_information2                      = p_rec.sta_information2,
145     sta_information3                      = p_rec.sta_information3,
146     sta_information4                      = p_rec.sta_information4,
147     sta_information5                      = p_rec.sta_information5,
148     sta_information6                      = p_rec.sta_information6,
149     sta_information7                      = p_rec.sta_information7,
150     sta_information8                      = p_rec.sta_information8,
151     sta_information9                      = p_rec.sta_information9,
152     sta_information10                     = p_rec.sta_information10,
153     sta_information11                     = p_rec.sta_information11,
154     sta_information12                     = p_rec.sta_information12,
155     sta_information13                     = p_rec.sta_information13,
156     sta_information14                     = p_rec.sta_information14,
157     sta_information15                     = p_rec.sta_information15,
158     sta_information16                     = p_rec.sta_information16,
159     sta_information17                     = p_rec.sta_information17,
160     sta_information18                     = p_rec.sta_information18,
161     sta_information19                     = p_rec.sta_information19,
162     sta_information20                     = p_rec.sta_information20,
163     sta_information21                     = p_rec.sta_information21,
164     sta_information22                     = p_rec.sta_information22,
165     sta_information23                     = p_rec.sta_information23,
166     sta_information24                     = p_rec.sta_information24,
167     sta_information25                     = p_rec.sta_information25,
168     sta_information26                     = p_rec.sta_information26,
169     sta_information27                     = p_rec.sta_information27,
170     sta_information28                     = p_rec.sta_information28,
171     sta_information29                     = p_rec.sta_information29,
172     sta_information30                     = p_rec.sta_information30
173     where   emp_state_tax_rule_id = p_rec.emp_state_tax_rule_id
174     and     effective_start_date = p_validation_start_date
175     and     effective_end_date   = p_validation_end_date;
176     --
177     pay_sta_shd.g_api_dml := false;   -- Unset the api dml status
178     --
179     -- Set the effective start and end dates
180     --
181     p_rec.effective_start_date := p_validation_start_date;
182     p_rec.effective_end_date   := p_validation_end_date;
183   End If;
184 --
185 hr_utility.set_location(' Leaving:'||l_proc, 15);
186 Exception
187   When hr_api.check_integrity_violated Then
188     -- A check constraint has been violated
189     pay_sta_shd.g_api_dml := false;   -- Unset the api dml status
190     pay_sta_shd.constraint_error
191       (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
192   When hr_api.unique_integrity_violated Then
193     -- Unique integrity has been violated
194     pay_sta_shd.g_api_dml := false;   -- Unset the api dml status
195     pay_sta_shd.constraint_error
196       (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
197   When Others Then
198     pay_sta_shd.g_api_dml := false;   -- Unset the api dml status
199     Raise;
200 End dt_update_dml;
201 --
202 -- ----------------------------------------------------------------------------
203 -- |------------------------------< update_dml >------------------------------|
204 -- ----------------------------------------------------------------------------
205 -- {Start Of Comments}
206 --
207 -- Description:
208 --   This procedure calls the dt_update_dml control logic which handles
209 --   the actual datetrack dml.
210 --
211 -- Prerequisites:
212 --   This is an internal private procedure which must be called from the upd
213 --   procedure.
214 --
215 -- In Parameters:
216 --   A Pl/Sql record structre.
217 --
218 -- Post Success:
219 --   Processing contines.
220 --
221 -- Post Failure:
222 --   No specific error handling is required within this procedure.
223 --
224 -- Developer Implementation Notes:
225 --   The update 'set' arguments list should be modified if any of your
226 --   attributes are not updateable.
227 --
228 -- Access Status:
229 --   Internal Row Handler Use Only.
230 --
231 -- {End Of Comments}
232 -- ----------------------------------------------------------------------------
233 Procedure update_dml
234       (p_rec                   in out nocopy pay_sta_shd.g_rec_type,
235        p_effective_date        in      	     date,
236        p_datetrack_mode        in      	     varchar2,
237        p_validation_start_date in      	     date,
238        p_validation_end_date   in      	     date) is
239 --
240   l_proc      varchar2(72) := g_package||'update_dml';
241 --
242 Begin
243   hr_utility.set_location('Entering:'||l_proc, 5);
244   --
245   dt_update_dml(p_rec                => p_rec,
246             p_effective_date         => p_effective_date,
247             p_datetrack_mode         => p_datetrack_mode,
248             p_validation_start_date  => p_validation_start_date,
249             p_validation_end_date    => p_validation_end_date);
250   --
251   hr_utility.set_location(' Leaving:'||l_proc, 10);
252 End update_dml;
253 --
254 -- ----------------------------------------------------------------------------
255 -- |----------------------------< dt_pre_update >-----------------------------|
256 -- ----------------------------------------------------------------------------
257 -- {Start Of Comments}
258 --
259 -- Description:
260 --   The dt_pre_update procedure controls the execution
261 --   of dml for the datetrack modes of: UPDATE, UPDATE_OVERRIDE
262 --   and UPDATE_CHANGE_INSERT only. The execution required is as
263 --   follows:
264 --
265 --   1) Providing the datetrack update mode is not 'CORRECTION'
266 --      then set the effective end date of the current row (this
267 --      will be the validation_start_date - 1).
268 --   2) If the datetrack mode is 'UPDATE_OVERRIDE' then call the
269 --      corresponding delete_dml process to delete any future rows
270 --      where the effective_start_date is greater than or equal to
271 --      the validation_start_date.
272 --   3) Call the insert_dml process to insert the new updated row
273 --      details..
274 --
275 -- Prerequisites:
276 --   This is an internal procedure which is called from the
277 --   pre_update procedure.
278 --
279 -- In Parameters:
280 --
281 -- Post Success:
282 --   Processing continues.
283 --
284 -- Post Failure:
285 --   If an error has occurred, an error message and exception will be raised
286 --   but not handled.
287 --
288 -- Developer Implementation Notes:
289 --   This is an internal procedure which is required by Datetrack. Don't
290 --   remove or modify.
291 --
292 -- Access Status:
293 --   Internal Row Handler Use Only.
294 --
295 -- {End Of Comments}
296 -- ----------------------------------------------------------------------------
297 Procedure dt_pre_update
298       (p_rec                   in out nocopy pay_sta_shd.g_rec_type,
299        p_effective_date        in      date,
300        p_datetrack_mode        in      varchar2,
301        p_validation_start_date in      date,
302        p_validation_end_date   in      date) is
303 --
304   l_proc         varchar2(72) := g_package||'dt_pre_update';
305   l_dummy_version_number number;
306 --
307 Begin
308   hr_utility.set_location('Entering:'||l_proc, 5);
309   If (p_datetrack_mode <> 'CORRECTION') then
310     hr_utility.set_location(l_proc, 10);
311     --
312     -- Update the current effective end date
313     --
314     pay_sta_shd.upd_effective_end_date
315      (p_effective_date         => p_effective_date,
316       p_base_key_value         => p_rec.emp_state_tax_rule_id,
317       p_new_effective_end_date => (p_validation_start_date - 1),
318       p_validation_start_date  => p_validation_start_date,
319       p_validation_end_date    => p_validation_end_date,
320       p_object_version_number  => l_dummy_version_number);
321     --
322     If (p_datetrack_mode = 'UPDATE_OVERRIDE') then
323       hr_utility.set_location(l_proc, 15);
324       --
325       -- As the datetrack mode is 'UPDATE_OVERRIDE' then we must
326       -- delete any future rows
327       --
328       pay_sta_del.delete_dml
329         (p_rec                 => p_rec,
330        p_effective_date        => p_effective_date,
331        p_datetrack_mode        => p_datetrack_mode,
332        p_validation_start_date => p_validation_start_date,
333        p_validation_end_date   => p_validation_end_date);
334     End If;
335     hr_utility.set_location(l_proc, 20);
336     --
337     -- We must now insert the updated row
338     --
339     pay_sta_ins.insert_dml
340       (p_rec                  => p_rec,
341        p_effective_date       => p_effective_date,
342        p_datetrack_mode       => p_datetrack_mode,
343        p_validation_start_date => p_validation_start_date,
344        p_validation_end_date  => p_validation_end_date);
345   End If;
346   hr_utility.set_location(' Leaving:'||l_proc, 20);
347 End dt_pre_update;
348 --
349 -- ----------------------------------------------------------------------------
350 -- |------------------------------< pre_update >------------------------------|
351 -- ----------------------------------------------------------------------------
352 -- {Start Of Comments}
353 --
354 -- Description:
355 --   This private procedure contains any processing which is required before
356 --   the update dml.
357 --
358 -- Prerequisites:
359 --   This is an internal procedure which is called from the upd procedure.
360 --
361 -- In Parameters:
362 --   A Pl/Sql record structre.
363 --
364 -- Post Success:
365 --   Processing continues.
366 --
367 -- Post Failure:
368 --   If an error has occurred, an error message and exception will be raised
369 --   but not handled.
370 --
371 -- Developer Implementation Notes:
372 --   Any pre-processing required before the update dml is issued should be
373 --   coded within this procedure. It is important to note that any 3rd party
374 --   maintenance should be reviewed before placing in this procedure. The call
375 --   to the dt_update_dml procedure should NOT be removed.
376 --
377 -- Access Status:
378 --   Internal Row Handler Use Only.
379 --
380 -- {End Of Comments}
381 -- ----------------------------------------------------------------------------
382 Procedure pre_update
383       (p_rec                   in out nocopy pay_sta_shd.g_rec_type,
384        p_effective_date        in      	     date,
385        p_datetrack_mode        in      	     varchar2,
386        p_validation_start_date in      	     date,
387        p_validation_end_date   in      	     date) is
388 --
389   l_proc      varchar2(72) := g_package||'pre_update';
390 --
391 Begin
392   hr_utility.set_location('Entering:'||l_proc, 5);
393   --
394   --
395   --
396   dt_pre_update
397     (p_rec                   => p_rec,
398      p_effective_date        => p_effective_date,
399      p_datetrack_mode        => p_datetrack_mode,
400      p_validation_start_date => p_validation_start_date,
401      p_validation_end_date   => p_validation_end_date);
402   --
403   hr_utility.set_location(' Leaving:'||l_proc, 10);
404 End pre_update;
405 --
406 -- ----------------------------------------------------------------------------
407 -- |-----------------------------< post_update >------------------------------|
408 -- ----------------------------------------------------------------------------
409 -- {Start Of Comments}
410 --
411 -- Description:
412 --   This private procedure contains any processing which is required after the
413 --   update dml.
414 --
415 -- Prerequisites:
416 --   This is an internal procedure which is called from the upd procedure.
417 --
418 -- In Parameters:
419 --   A Pl/Sql record structre.
420 --
421 -- Post Success:
422 --   Processing continues.
423 --
424 -- Post Failure:
425 --   If an error has occurred, an error message and exception will be raised
426 --   but not handled.
427 --
428 -- Developer Implementation Notes:
429 --   Any post-processing required after the update dml is issued should be
430 --   coded within this procedure. It is important to note that any 3rd party
431 --   maintenance should be reviewed before placing in this procedure.
432 --
433 -- Access Status:
434 --   Internal Row Handler Use Only.
435 --
436 -- {End Of Comments}
437 -- ----------------------------------------------------------------------------
438 Procedure post_update
439       (p_rec                   in pay_sta_shd.g_rec_type,
440        p_effective_date        in date,
441        p_datetrack_mode        in varchar2,
442        p_validation_start_date in date,
443        p_validation_end_date   in date) is
444 --
445   l_proc      varchar2(72) := g_package||'post_update';
446 --
447 Begin
448   hr_utility.set_location('Entering:'||l_proc, 5);
449 --
450   --
451   -- Start of API User Hook for post_update.
452   --
453   begin
454     --
455  /*    pay_sta_rku.after_update
456       (
457   p_emp_state_tax_rule_id      =>p_rec.emp_state_tax_rule_id
458  ,p_effective_start_date       =>p_rec.effective_start_date
459  ,p_effective_end_date         =>p_rec.effective_end_date
460  ,p_additional_wa_amount       =>p_rec.additional_wa_amount
461  ,p_filing_status_code         =>p_rec.filing_status_code
462  ,p_remainder_percent          =>p_rec.remainder_percent
463  ,p_secondary_wa               =>p_rec.secondary_wa
464  ,p_sit_additional_tax         =>p_rec.sit_additional_tax
465  ,p_sit_override_amount        =>p_rec.sit_override_amount
466  ,p_sit_override_rate          =>p_rec.sit_override_rate
467  ,p_withholding_allowances     =>p_rec.withholding_allowances
468  ,p_excessive_wa_reject_date   =>p_rec.excessive_wa_reject_date
469  ,p_sdi_exempt                 =>p_rec.sdi_exempt
470  ,p_sit_exempt                 =>p_rec.sit_exempt
471  ,p_sit_optional_calc_ind      =>p_rec.sit_optional_calc_ind
472  ,p_state_non_resident_cert    =>p_rec.state_non_resident_cert
473  ,p_sui_exempt                 =>p_rec.sui_exempt
474  ,p_wc_exempt                  =>p_rec.wc_exempt
475  ,p_wage_exempt                =>p_rec.wage_exempt
476  ,p_sui_wage_base_override_amoun =>p_rec.sui_wage_base_override_amount
477  ,p_supp_tax_override_rate     =>p_rec.supp_tax_override_rate
478  ,p_object_version_number      =>p_rec.object_version_number
479  ,p_effective_date             =>p_effective_date
480  ,p_datetrack_mode             =>p_datetrack_mode
481  ,p_validation_start_date      =>p_validation_start_date
482  ,p_validation_end_date        =>p_validation_end_date
483  ,p_effective_start_date_o     =>pay_sta_shd.g_old_rec.effective_start_date
484  ,p_effective_end_date_o       =>pay_sta_shd.g_old_rec.effective_end_date
485  ,p_assignment_id_o            =>pay_sta_shd.g_old_rec.assignment_id
486  ,p_state_code_o               =>pay_sta_shd.g_old_rec.state_code
487  ,p_jurisdiction_code_o        =>pay_sta_shd.g_old_rec.jurisdiction_code
488  ,p_business_group_id_o        =>pay_sta_shd.g_old_rec.business_group_id
489  ,p_additional_wa_amount_o     =>pay_sta_shd.g_old_rec.additional_wa_amount
490  ,p_filing_status_code_o       =>pay_sta_shd.g_old_rec.filing_status_code
491  ,p_remainder_percent_o        =>pay_sta_shd.g_old_rec.remainder_percent
492  ,p_secondary_wa_o             =>pay_sta_shd.g_old_rec.secondary_wa
493  ,p_sit_additional_tax_o       =>pay_sta_shd.g_old_rec.sit_additional_tax
494  ,p_sit_override_amount_o      =>pay_sta_shd.g_old_rec.sit_override_amount
495  ,p_sit_override_rate_o        =>pay_sta_shd.g_old_rec.sit_override_rate
496  ,p_withholding_allowances_o   =>pay_sta_shd.g_old_rec.withholding_allowances
497  ,p_excessive_wa_reject_date_o =>pay_sta_shd.g_old_rec.excessive_wa_reject_date
498  ,p_sdi_exempt_o               =>pay_sta_shd.g_old_rec.sdi_exempt
499  ,p_sit_exempt_o               =>pay_sta_shd.g_old_rec.sit_exempt
500  ,p_sit_optional_calc_ind_o    =>pay_sta_shd.g_old_rec.sit_optional_calc_ind
501  ,p_state_non_resident_cert_o  =>pay_sta_shd.g_old_rec.state_non_resident_cert
502  ,p_sui_exempt_o               =>pay_sta_shd.g_old_rec.sui_exempt
503  ,p_wc_exempt_o                =>pay_sta_shd.g_old_rec.wc_exempt
504  ,p_wage_exempt_o              =>pay_sta_shd.g_old_rec.wage_exempt
505  ,p_sui_wage_base_override_amo_o =>
506                            pay_sta_shd.g_old_rec.sui_wage_base_override_amount
507  ,p_supp_tax_override_rate_o   =>pay_sta_shd.g_old_rec.supp_tax_override_rate
508  ,p_object_version_number_o    =>pay_sta_shd.g_old_rec.object_version_number
509       );
510     --
511   exception
512     --
513     when hr_api.cannot_find_prog_unit then
514       --
515       hr_api.cannot_find_prog_unit_error
516         (p_module_name => 'PAY_US_EMP_STATE_TAX_RULES_F
517         ,p_hook_type   => 'AU');
518       --
519  */
520     null;
521     --
522   end;
523   --
524   -- End of API User Hook for post_update.
525   --
526   --
527   hr_utility.set_location(' Leaving:'||l_proc, 10);
528 End post_update;
529 --
530 -- ----------------------------------------------------------------------------
531 -- |-----------------------------< convert_defs >-----------------------------|
532 -- ----------------------------------------------------------------------------
533 -- {Start Of Comments}
534 --
535 -- Description:
536 --   The Convert_Defs procedure has one very important function:
537 --   It must return the record structure for the row with all system defaulted
538 --   values converted into its corresponding parameter value for update. When
539 --   we attempt to update a row through the Upd process , certain
540 --   parameters can be defaulted which enables flexibility in the calling of
541 --   the upd process (e.g. only attributes which need to be updated need to be
542 --   specified). For the upd process to determine which attributes
543 --   have NOT been specified we need to check if the parameter has a reserved
544 --   system default value. Therefore, for all parameters which have a
545 --   corresponding reserved system default mechanism specified we need to
546 --   check if a system default is being used. If a system default is being
547 --   used then we convert the defaulted value into its corresponding attribute
548 --   value held in the g_old_rec data structure.
549 --
550 -- Prerequisites:
551 --   This private function can only be called from the upd process.
552 --
553 -- In Parameters:
554 --   A Pl/Sql record structre.
555 --
556 -- Post Success:
557 --   The record structure will be returned with all system defaulted parameter
558 --   values converted into its current row attribute value.
559 --
560 -- Post Failure:
561 --   No direct error handling is required within this function. Any possible
562 --   errors within this procedure will be a PL/SQL value error due to
563 --   conversion of datatypes or data lengths.
564 --
565 -- Developer Implementation Notes:
566 --   None.
567 --
568 -- Access Status:
569 --   Internal Row Handler Use Only.
570 --
571 -- {End Of Comments}
572 -- ----------------------------------------------------------------------------
573 Procedure convert_defs(p_rec in out nocopy pay_sta_shd.g_rec_type) is
574 --
575   l_proc  varchar2(72) := g_package||'convert_defs';
576 --
577 Begin
578   --
579   hr_utility.set_location('Entering:'||l_proc, 5);
580   --
581   -- We must now examine each argument value in the
582   -- p_rec plsql record structure
583   -- to see if a system default is being used. If a system default
584   -- is being used then we must set to the 'current' argument value.
585   --
586   If (p_rec.assignment_id = hr_api.g_number) then
587     p_rec.assignment_id :=
588     pay_sta_shd.g_old_rec.assignment_id;
589   End If;
590   If (p_rec.state_code = hr_api.g_varchar2) then
591     p_rec.state_code :=
592     pay_sta_shd.g_old_rec.state_code;
593   End If;
594   If (p_rec.jurisdiction_code = hr_api.g_varchar2) then
595     p_rec.jurisdiction_code :=
596     pay_sta_shd.g_old_rec.jurisdiction_code;
597   End If;
598   If (p_rec.business_group_id = hr_api.g_number) then
599     p_rec.business_group_id :=
600     pay_sta_shd.g_old_rec.business_group_id;
601   End If;
602   If (p_rec.additional_wa_amount = hr_api.g_number) then
603     p_rec.additional_wa_amount :=
604     pay_sta_shd.g_old_rec.additional_wa_amount;
605   End If;
606   If (p_rec.filing_status_code = hr_api.g_varchar2) then
607     p_rec.filing_status_code :=
608     pay_sta_shd.g_old_rec.filing_status_code;
609   End If;
610   If (p_rec.remainder_percent = hr_api.g_number) then
611     p_rec.remainder_percent :=
612     pay_sta_shd.g_old_rec.remainder_percent;
613   End If;
614   If (p_rec.secondary_wa = hr_api.g_number) then
615     p_rec.secondary_wa :=
616     pay_sta_shd.g_old_rec.secondary_wa;
617   End If;
618   If (p_rec.sit_additional_tax = hr_api.g_number) then
619     p_rec.sit_additional_tax :=
620     pay_sta_shd.g_old_rec.sit_additional_tax;
621   End If;
622   If (p_rec.sit_override_amount = hr_api.g_number) then
623     p_rec.sit_override_amount :=
624     pay_sta_shd.g_old_rec.sit_override_amount;
625   End If;
626   If (p_rec.sit_override_rate = hr_api.g_number) then
627     p_rec.sit_override_rate :=
628     pay_sta_shd.g_old_rec.sit_override_rate;
629   End If;
630   If (p_rec.withholding_allowances = hr_api.g_number) then
631     p_rec.withholding_allowances :=
632     pay_sta_shd.g_old_rec.withholding_allowances;
633   End If;
634   If (p_rec.excessive_wa_reject_date = hr_api.g_date) then
635     p_rec.excessive_wa_reject_date :=
636     pay_sta_shd.g_old_rec.excessive_wa_reject_date;
637   End If;
638   If (p_rec.sdi_exempt = hr_api.g_varchar2) then
639     p_rec.sdi_exempt :=
640     pay_sta_shd.g_old_rec.sdi_exempt;
641   End If;
642   If (p_rec.sit_exempt = hr_api.g_varchar2) then
643     p_rec.sit_exempt :=
644     pay_sta_shd.g_old_rec.sit_exempt;
645   End If;
646   If (p_rec.sit_optional_calc_ind = hr_api.g_varchar2) then
647     p_rec.sit_optional_calc_ind :=
648     pay_sta_shd.g_old_rec.sit_optional_calc_ind;
649   End If;
650   If (p_rec.state_non_resident_cert = hr_api.g_varchar2) then
651     p_rec.state_non_resident_cert :=
652     pay_sta_shd.g_old_rec.state_non_resident_cert;
653   End If;
654   If (p_rec.sui_exempt = hr_api.g_varchar2) then
655     p_rec.sui_exempt :=
656     pay_sta_shd.g_old_rec.sui_exempt;
657   End If;
658   If (p_rec.wc_exempt = hr_api.g_varchar2) then
659     p_rec.wc_exempt :=
660     pay_sta_shd.g_old_rec.wc_exempt;
661   End If;
662   If (p_rec.wage_exempt = hr_api.g_varchar2) then
663     p_rec.wage_exempt :=
664     pay_sta_shd.g_old_rec.wage_exempt;
665   End If;
666   If (p_rec.sui_wage_base_override_amount = hr_api.g_number) then
667     p_rec.sui_wage_base_override_amount :=
668     pay_sta_shd.g_old_rec.sui_wage_base_override_amount;
669   End If;
670   If (p_rec.supp_tax_override_rate = hr_api.g_number) then
671     p_rec.supp_tax_override_rate :=
672     pay_sta_shd.g_old_rec.supp_tax_override_rate;
673   End If;
674   If (p_rec.attribute_category = hr_api.g_varchar2) then
675     p_rec.attribute_category :=
676     pay_sta_shd.g_old_rec.attribute_category;
677   End If;
678   If (p_rec.attribute1 = hr_api.g_varchar2) then
679     p_rec.attribute1 :=
680     pay_sta_shd.g_old_rec.attribute1;
681   End If;
682   If (p_rec.attribute2 = hr_api.g_varchar2) then
683     p_rec.attribute2 :=
684     pay_sta_shd.g_old_rec.attribute2;
685   End If;
686   If (p_rec.attribute3 = hr_api.g_varchar2) then
687     p_rec.attribute3 :=
688     pay_sta_shd.g_old_rec.attribute3;
689   End If;
690   If (p_rec.attribute4 = hr_api.g_varchar2) then
691     p_rec.attribute4 :=
692     pay_sta_shd.g_old_rec.attribute4;
693   End If;
694   If (p_rec.attribute5 = hr_api.g_varchar2) then
695     p_rec.attribute5 :=
696     pay_sta_shd.g_old_rec.attribute5;
697   End If;
698   If (p_rec.attribute6 = hr_api.g_varchar2) then
699     p_rec.attribute6 :=
700     pay_sta_shd.g_old_rec.attribute6;
701   End If;
702   If (p_rec.attribute7 = hr_api.g_varchar2) then
703     p_rec.attribute7 :=
704     pay_sta_shd.g_old_rec.attribute7;
705   End If;
706   If (p_rec.attribute8 = hr_api.g_varchar2) then
707     p_rec.attribute8 :=
708     pay_sta_shd.g_old_rec.attribute8;
709   End If;
710   If (p_rec.attribute9 = hr_api.g_varchar2) then
711     p_rec.attribute9 :=
712     pay_sta_shd.g_old_rec.attribute9;
713   End If;
714   If (p_rec.attribute10 = hr_api.g_varchar2) then
715     p_rec.attribute10 :=
716     pay_sta_shd.g_old_rec.attribute10;
717   End If;
718   If (p_rec.attribute11 = hr_api.g_varchar2) then
719     p_rec.attribute11 :=
720     pay_sta_shd.g_old_rec.attribute11;
721   End If;
722   If (p_rec.attribute12 = hr_api.g_varchar2) then
723     p_rec.attribute12 :=
724     pay_sta_shd.g_old_rec.attribute12;
725   End If;
726   If (p_rec.attribute13 = hr_api.g_varchar2) then
727     p_rec.attribute13 :=
728     pay_sta_shd.g_old_rec.attribute13;
729   End If;
730   If (p_rec.attribute14 = hr_api.g_varchar2) then
731     p_rec.attribute14 :=
732     pay_sta_shd.g_old_rec.attribute14;
733   End If;
734   If (p_rec.attribute15 = hr_api.g_varchar2) then
735     p_rec.attribute15 :=
736     pay_sta_shd.g_old_rec.attribute15;
737   End If;
738   If (p_rec.attribute16 = hr_api.g_varchar2) then
739     p_rec.attribute16 :=
740     pay_sta_shd.g_old_rec.attribute16;
741   End If;
742   If (p_rec.attribute17 = hr_api.g_varchar2) then
743     p_rec.attribute17 :=
744     pay_sta_shd.g_old_rec.attribute17;
745   End If;
746   If (p_rec.attribute18 = hr_api.g_varchar2) then
747     p_rec.attribute18 :=
748     pay_sta_shd.g_old_rec.attribute18;
749   End If;
750   If (p_rec.attribute19 = hr_api.g_varchar2) then
751     p_rec.attribute19 :=
752     pay_sta_shd.g_old_rec.attribute19;
753   End If;
754   If (p_rec.attribute20 = hr_api.g_varchar2) then
755     p_rec.attribute20 :=
756     pay_sta_shd.g_old_rec.attribute20;
757   End If;
758   If (p_rec.attribute21 = hr_api.g_varchar2) then
759     p_rec.attribute21 :=
760     pay_sta_shd.g_old_rec.attribute21;
761   End If;
762   If (p_rec.attribute22 = hr_api.g_varchar2) then
763     p_rec.attribute22 :=
764     pay_sta_shd.g_old_rec.attribute22;
765   End If;
766   If (p_rec.attribute23 = hr_api.g_varchar2) then
767     p_rec.attribute23 :=
768     pay_sta_shd.g_old_rec.attribute23;
769   End If;
770   If (p_rec.attribute24 = hr_api.g_varchar2) then
771     p_rec.attribute24 :=
772     pay_sta_shd.g_old_rec.attribute24;
773   End If;
774   If (p_rec.attribute25 = hr_api.g_varchar2) then
775     p_rec.attribute25 :=
776     pay_sta_shd.g_old_rec.attribute25;
777   End If;
778   If (p_rec.attribute26 = hr_api.g_varchar2) then
779     p_rec.attribute26 :=
780     pay_sta_shd.g_old_rec.attribute26;
781   End If;
782   If (p_rec.attribute27 = hr_api.g_varchar2) then
783     p_rec.attribute27 :=
784     pay_sta_shd.g_old_rec.attribute27;
785   End If;
786   If (p_rec.attribute28 = hr_api.g_varchar2) then
787     p_rec.attribute28 :=
788     pay_sta_shd.g_old_rec.attribute28;
789   End If;
790   If (p_rec.attribute29 = hr_api.g_varchar2) then
791     p_rec.attribute29 :=
792     pay_sta_shd.g_old_rec.attribute29;
793   End If;
794   If (p_rec.attribute30 = hr_api.g_varchar2) then
795     p_rec.attribute30 :=
796     pay_sta_shd.g_old_rec.attribute30;
797   End If;
798   If (p_rec.sta_information_category = hr_api.g_varchar2) then
799     p_rec.sta_information_category :=
800     pay_sta_shd.g_old_rec.sta_information_category;
801   End If;
802   If (p_rec.sta_information1 = hr_api.g_varchar2) then
803     p_rec.sta_information1 :=
804     pay_sta_shd.g_old_rec.sta_information1;
805   End If;
806   If (p_rec.sta_information2 = hr_api.g_varchar2) then
807     p_rec.sta_information2 :=
808     pay_sta_shd.g_old_rec.sta_information2;
809   End If;
810   If (p_rec.sta_information3 = hr_api.g_varchar2) then
811     p_rec.sta_information3 :=
812     pay_sta_shd.g_old_rec.sta_information3;
813   End If;
814   If (p_rec.sta_information4 = hr_api.g_varchar2) then
815     p_rec.sta_information4 :=
816     pay_sta_shd.g_old_rec.sta_information4;
817   End If;
818   If (p_rec.sta_information5 = hr_api.g_varchar2) then
819     p_rec.sta_information5 :=
820     pay_sta_shd.g_old_rec.sta_information5;
821   End If;
822   If (p_rec.sta_information6 = hr_api.g_varchar2) then
823     p_rec.sta_information6 :=
824     pay_sta_shd.g_old_rec.sta_information6;
825   End If;
826   If (p_rec.sta_information7 = hr_api.g_varchar2) then
827     p_rec.sta_information7 :=
828     pay_sta_shd.g_old_rec.sta_information7;
829   End If;
830   If (p_rec.sta_information8 = hr_api.g_varchar2) then
831     p_rec.sta_information8 :=
832     pay_sta_shd.g_old_rec.sta_information8;
833   End If;
834   If (p_rec.sta_information9 = hr_api.g_varchar2) then
835     p_rec.sta_information9 :=
836     pay_sta_shd.g_old_rec.sta_information9;
837   End If;
838   If (p_rec.sta_information10 = hr_api.g_varchar2) then
839     p_rec.sta_information10 :=
840     pay_sta_shd.g_old_rec.sta_information10;
841   End If;
842   If (p_rec.sta_information11 = hr_api.g_varchar2) then
843     p_rec.sta_information11 :=
844     pay_sta_shd.g_old_rec.sta_information11;
845   End If;
846   If (p_rec.sta_information12 = hr_api.g_varchar2) then
847     p_rec.sta_information12 :=
848     pay_sta_shd.g_old_rec.sta_information12;
849   End If;
850   If (p_rec.sta_information13 = hr_api.g_varchar2) then
851     p_rec.sta_information13 :=
852     pay_sta_shd.g_old_rec.sta_information13;
853   End If;
854   If (p_rec.sta_information14 = hr_api.g_varchar2) then
855     p_rec.sta_information14 :=
856     pay_sta_shd.g_old_rec.sta_information14;
857   End If;
858   If (p_rec.sta_information15 = hr_api.g_varchar2) then
859     p_rec.sta_information15 :=
860     pay_sta_shd.g_old_rec.sta_information15;
861   End If;
862   If (p_rec.sta_information16 = hr_api.g_varchar2) then
863     p_rec.sta_information16 :=
864     pay_sta_shd.g_old_rec.sta_information16;
865   End If;
866   If (p_rec.sta_information17 = hr_api.g_varchar2) then
867     p_rec.sta_information17 :=
868     pay_sta_shd.g_old_rec.sta_information17;
869   End If;
870   If (p_rec.sta_information18 = hr_api.g_varchar2) then
871     p_rec.sta_information18 :=
872     pay_sta_shd.g_old_rec.sta_information18;
873   End If;
874   If (p_rec.sta_information19 = hr_api.g_varchar2) then
875     p_rec.sta_information19 :=
876     pay_sta_shd.g_old_rec.sta_information19;
877   End If;
878   If (p_rec.sta_information20 = hr_api.g_varchar2) then
879     p_rec.sta_information20 :=
880     pay_sta_shd.g_old_rec.sta_information20;
881   End If;
882   If (p_rec.sta_information21 = hr_api.g_varchar2) then
883     p_rec.sta_information21 :=
884     pay_sta_shd.g_old_rec.sta_information21;
885   End If;
886   If (p_rec.sta_information22 = hr_api.g_varchar2) then
887     p_rec.sta_information22 :=
888     pay_sta_shd.g_old_rec.sta_information22;
889   End If;
890   If (p_rec.sta_information23 = hr_api.g_varchar2) then
891     p_rec.sta_information23 :=
892     pay_sta_shd.g_old_rec.sta_information23;
893   End If;
894   If (p_rec.sta_information24 = hr_api.g_varchar2) then
895     p_rec.sta_information24 :=
896     pay_sta_shd.g_old_rec.sta_information24;
897   End If;
898   If (p_rec.sta_information25 = hr_api.g_varchar2) then
899     p_rec.sta_information25 :=
900     pay_sta_shd.g_old_rec.sta_information25;
901   End If;
902   If (p_rec.sta_information26 = hr_api.g_varchar2) then
903     p_rec.sta_information26 :=
904     pay_sta_shd.g_old_rec.sta_information26;
905   End If;
906   If (p_rec.sta_information27 = hr_api.g_varchar2) then
907     p_rec.sta_information27 :=
908     pay_sta_shd.g_old_rec.sta_information27;
909   End If;
910   If (p_rec.sta_information28 = hr_api.g_varchar2) then
911     p_rec.sta_information28 :=
912     pay_sta_shd.g_old_rec.sta_information28;
913   End If;
914   If (p_rec.sta_information29 = hr_api.g_varchar2) then
915     p_rec.sta_information29 :=
916     pay_sta_shd.g_old_rec.sta_information29;
917   End If;
918   If (p_rec.sta_information30 = hr_api.g_varchar2) then
919     p_rec.sta_information30 :=
920     pay_sta_shd.g_old_rec.sta_information30;
921   End If;
922 
923   --
924   hr_utility.set_location(' Leaving:'||l_proc, 10);
925 --
926 End convert_defs;
927 --
928 -- ----------------------------------------------------------------------------
929 -- |---------------------------------< upd >----------------------------------|
930 -- ----------------------------------------------------------------------------
931 Procedure upd
932   (
933   p_rec                  in out nocopy	pay_sta_shd.g_rec_type,
934   p_effective_date       in       	date,
935   p_datetrack_mode       in       	varchar2
936   ) is
937 --
938   l_proc                  varchar2(72) := g_package||'upd';
939   l_validation_start_date      date;
940   l_validation_end_date        date;
941 --
942 Begin
943   hr_utility.set_location('Entering:'||l_proc, 5);
944   --
945   -- Ensure that the DateTrack update mode is valid
946   --
947   dt_api.validate_dt_upd_mode(p_datetrack_mode => p_datetrack_mode);
948   --
949   -- We must lock the row which we need to update.
950   --
951   pay_sta_shd.lck
952       (p_effective_date        => p_effective_date,
953        p_datetrack_mode        => p_datetrack_mode,
954        p_emp_state_tax_rule_id => p_rec.emp_state_tax_rule_id,
955        p_object_version_number => p_rec.object_version_number,
956        p_validation_start_date => l_validation_start_date,
957        p_validation_end_date   => l_validation_end_date);
958   --
959   -- 1. During an update system defaults are used to determine if
960   --    arguments have been defaulted or not. We must therefore
961   --    derive the full record structure values to be updated.
962   --
963   -- 2. Call the supporting update validate operations.
964   --
965   convert_defs(p_rec);
966   pay_sta_bus.update_validate
967       (p_rec                   => p_rec,
968        p_effective_date        => p_effective_date,
969        p_datetrack_mode        => p_datetrack_mode,
970        p_validation_start_date => l_validation_start_date,
971        p_validation_end_date   => l_validation_end_date);
972   --
973   -- Call the supporting pre-update operation
974   --
975   pre_update
976       (p_rec                   => p_rec,
977        p_effective_date        => p_effective_date,
978        p_datetrack_mode        => p_datetrack_mode,
979        p_validation_start_date => l_validation_start_date,
980        p_validation_end_date   => l_validation_end_date);
981   --
982   -- Update the row.
983   --
984   update_dml
985       (p_rec                   => p_rec,
986        p_effective_date        => p_effective_date,
987        p_datetrack_mode        => p_datetrack_mode,
988        p_validation_start_date => l_validation_start_date,
989        p_validation_end_date   => l_validation_end_date);
990   --
991   -- Call the supporting post-update operation
992   --
993   post_update
994       (p_rec                   => p_rec,
995        p_effective_date        => p_effective_date,
996        p_datetrack_mode        => p_datetrack_mode,
997        p_validation_start_date => l_validation_start_date,
998        p_validation_end_date   => l_validation_end_date);
999 End upd;
1000 --
1001 -- ----------------------------------------------------------------------------
1002 -- |---------------------------------< upd >----------------------------------|
1003 -- ----------------------------------------------------------------------------
1004 Procedure upd
1005   (
1006   p_emp_state_tax_rule_id        in number,
1007   p_effective_start_date         out nocopy date,
1008   p_effective_end_date           out nocopy date,
1009   p_additional_wa_amount         in number           default hr_api.g_number,
1010   p_filing_status_code           in varchar2         default hr_api.g_varchar2,
1011   p_remainder_percent            in number           default hr_api.g_number,
1012   p_secondary_wa                 in number           default hr_api.g_number,
1013   p_sit_additional_tax           in number           default hr_api.g_number,
1014   p_sit_override_amount          in number           default hr_api.g_number,
1015   p_sit_override_rate            in number           default hr_api.g_number,
1016   p_withholding_allowances       in number           default hr_api.g_number,
1017   p_excessive_wa_reject_date     in date             default hr_api.g_date,
1018   p_sdi_exempt                   in varchar2         default hr_api.g_varchar2,
1019   p_sit_exempt                   in varchar2         default hr_api.g_varchar2,
1020   p_sit_optional_calc_ind        in varchar2         default hr_api.g_varchar2,
1021   p_state_non_resident_cert      in varchar2         default hr_api.g_varchar2,
1022   p_sui_exempt                   in varchar2         default hr_api.g_varchar2,
1023   p_wc_exempt                    in varchar2         default hr_api.g_varchar2,
1024   p_wage_exempt                  in varchar2         default hr_api.g_varchar2,
1025   p_sui_wage_base_override_amoun in number           default hr_api.g_number,
1026   p_supp_tax_override_rate       in number           default hr_api.g_number,
1027   p_object_version_number        in out nocopy number,
1028   p_effective_date             in date,
1029   p_datetrack_mode             in varchar2,
1030   p_attribute_category          in varchar2         default hr_api.g_varchar2,
1031   p_attribute1                  in varchar2         default hr_api.g_varchar2,
1032   p_attribute2                  in varchar2         default hr_api.g_varchar2,
1033   p_attribute3                  in varchar2         default hr_api.g_varchar2,
1034   p_attribute4                  in varchar2         default hr_api.g_varchar2,
1035   p_attribute5                  in varchar2         default hr_api.g_varchar2,
1036   p_attribute6                  in varchar2         default hr_api.g_varchar2,
1037   p_attribute7                  in varchar2         default hr_api.g_varchar2,
1038   p_attribute8                  in varchar2         default hr_api.g_varchar2,
1039   p_attribute9                  in varchar2         default hr_api.g_varchar2,
1040   p_attribute10                 in varchar2         default hr_api.g_varchar2,
1041   p_attribute11                 in varchar2         default hr_api.g_varchar2,
1042   p_attribute12                 in varchar2         default hr_api.g_varchar2,
1043   p_attribute13                 in varchar2         default hr_api.g_varchar2,
1044   p_attribute14                 in varchar2         default hr_api.g_varchar2,
1045   p_attribute15                 in varchar2         default hr_api.g_varchar2,
1046   p_attribute16                 in varchar2         default hr_api.g_varchar2,
1047   p_attribute17                 in varchar2         default hr_api.g_varchar2,
1048   p_attribute18                 in varchar2         default hr_api.g_varchar2,
1049   p_attribute19                 in varchar2         default hr_api.g_varchar2,
1050   p_attribute20                 in varchar2         default hr_api.g_varchar2,
1051   p_attribute21                 in varchar2         default hr_api.g_varchar2,
1052   p_attribute22                 in varchar2         default hr_api.g_varchar2,
1053   p_attribute23                 in varchar2         default hr_api.g_varchar2,
1054   p_attribute24                 in varchar2         default hr_api.g_varchar2,
1055   p_attribute25                 in varchar2         default hr_api.g_varchar2,
1056   p_attribute26                 in varchar2         default hr_api.g_varchar2,
1057   p_attribute27                 in varchar2         default hr_api.g_varchar2,
1058   p_attribute28                 in varchar2         default hr_api.g_varchar2,
1059   p_attribute29                 in varchar2         default hr_api.g_varchar2,
1060   p_attribute30                 in varchar2         default hr_api.g_varchar2,
1061   p_sta_information_category    in varchar2         default hr_api.g_varchar2,
1062   p_sta_information1            in varchar2         default hr_api.g_varchar2,
1063   p_sta_information2            in varchar2         default hr_api.g_varchar2,
1064   p_sta_information3            in varchar2         default hr_api.g_varchar2,
1065   p_sta_information4            in varchar2         default hr_api.g_varchar2,
1066   p_sta_information5            in varchar2         default hr_api.g_varchar2,
1067   p_sta_information6            in varchar2         default hr_api.g_varchar2,
1068   p_sta_information7            in varchar2         default hr_api.g_varchar2,
1069   p_sta_information8            in varchar2         default hr_api.g_varchar2,
1070   p_sta_information9            in varchar2         default hr_api.g_varchar2,
1071   p_sta_information10           in varchar2         default hr_api.g_varchar2,
1072   p_sta_information11           in varchar2         default hr_api.g_varchar2,
1073   p_sta_information12           in varchar2         default hr_api.g_varchar2,
1074   p_sta_information13           in varchar2         default hr_api.g_varchar2,
1075   p_sta_information14           in varchar2         default hr_api.g_varchar2,
1076   p_sta_information15           in varchar2         default hr_api.g_varchar2,
1077   p_sta_information16           in varchar2         default hr_api.g_varchar2,
1078   p_sta_information17           in varchar2         default hr_api.g_varchar2,
1079   p_sta_information18           in varchar2         default hr_api.g_varchar2,
1080   p_sta_information19           in varchar2         default hr_api.g_varchar2,
1081   p_sta_information20           in varchar2         default hr_api.g_varchar2,
1082   p_sta_information21           in varchar2         default hr_api.g_varchar2,
1083   p_sta_information22           in varchar2         default hr_api.g_varchar2,
1084   p_sta_information23           in varchar2         default hr_api.g_varchar2,
1085   p_sta_information24           in varchar2         default hr_api.g_varchar2,
1086   p_sta_information25           in varchar2         default hr_api.g_varchar2,
1087   p_sta_information26           in varchar2         default hr_api.g_varchar2,
1088   p_sta_information27           in varchar2         default hr_api.g_varchar2,
1089   p_sta_information28           in varchar2         default hr_api.g_varchar2,
1090   p_sta_information29           in varchar2         default hr_api.g_varchar2,
1091   p_sta_information30           in varchar2         default hr_api.g_varchar2
1092   ) is
1093 --
1094   l_rec            pay_sta_shd.g_rec_type;
1095   l_proc      varchar2(72) := g_package||'upd';
1096 --
1097 Begin
1098   hr_utility.set_location('Entering:'||l_proc, 5);
1099   --
1100   -- Call conversion function to turn arguments into the
1101   -- l_rec structure.
1102   --
1103   l_rec :=
1104   pay_sta_shd.convert_args
1105   (
1106   p_emp_state_tax_rule_id,
1107   null,
1108   null,
1109   hr_api.g_number,
1110   hr_api.g_varchar2,
1111   hr_api.g_varchar2,
1112   hr_api.g_number,
1113   p_additional_wa_amount,
1114   p_filing_status_code,
1115   p_remainder_percent,
1116   p_secondary_wa,
1117   p_sit_additional_tax,
1118   p_sit_override_amount,
1119   p_sit_override_rate,
1120   p_withholding_allowances,
1121   p_excessive_wa_reject_date,
1122   p_sdi_exempt,
1123   p_sit_exempt,
1124   p_sit_optional_calc_ind,
1125   p_state_non_resident_cert,
1126   p_sui_exempt,
1127   p_wc_exempt,
1128   p_wage_exempt,
1129   p_sui_wage_base_override_amoun,
1130   p_supp_tax_override_rate,
1131   p_object_version_number,
1132   p_attribute_category,
1133   p_attribute1,
1134   p_attribute2,
1135   p_attribute3,
1136   p_attribute4,
1137   p_attribute5,
1138   p_attribute6,
1139   p_attribute7,
1140   p_attribute8,
1141   p_attribute9,
1142   p_attribute10,
1143   p_attribute11,
1144   p_attribute12,
1145   p_attribute13,
1146   p_attribute14,
1147   p_attribute15,
1148   p_attribute16,
1149   p_attribute17,
1150   p_attribute18,
1151   p_attribute19,
1152   p_attribute20,
1153   p_attribute21,
1154   p_attribute22,
1155   p_attribute23,
1156   p_attribute24,
1157   p_attribute25,
1158   p_attribute26,
1159   p_attribute27,
1160   p_attribute28,
1161   p_attribute29,
1162   p_attribute30,
1163   p_sta_information_category,
1164   p_sta_information1,
1165   p_sta_information2,
1166   p_sta_information3,
1167   p_sta_information4,
1168   p_sta_information5,
1169   p_sta_information6,
1170   p_sta_information7,
1171   p_sta_information8,
1172   p_sta_information9,
1173   p_sta_information10,
1174   p_sta_information11,
1175   p_sta_information12,
1176   p_sta_information13,
1177   p_sta_information14,
1178   p_sta_information15,
1179   p_sta_information16,
1180   p_sta_information17,
1181   p_sta_information18,
1182   p_sta_information19,
1183   p_sta_information20,
1184   p_sta_information21,
1185   p_sta_information22,
1186   p_sta_information23,
1187   p_sta_information24,
1188   p_sta_information25,
1189   p_sta_information26,
1190   p_sta_information27,
1191   p_sta_information28,
1192   p_sta_information29,
1193   p_sta_information30
1194   );
1195   --
1196   -- Having converted the arguments into the
1197   -- plsql record structure we call the corresponding record
1198   -- business process.
1199   --
1200   upd(l_rec, p_effective_date, p_datetrack_mode);
1201   p_object_version_number       := l_rec.object_version_number;
1202   p_effective_start_date        := l_rec.effective_start_date;
1203   p_effective_end_date          := l_rec.effective_end_date;
1204   --
1205   --
1206   hr_utility.set_location(' Leaving:'||l_proc, 10);
1207 End upd;
1208 --
1209 end pay_sta_upd;