DBA Data[Home] [Help]

PACKAGE BODY: APPS.PQP_PTY_SHD

Source


1 Package Body pqp_pty_shd as
2 /* $Header: pqptyrhi.pkb 120.0.12000000.1 2007/01/16 04:29:01 appldev noship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- |                     Private Global Definitions                           |
6 -- ----------------------------------------------------------------------------
7 --
8 g_package  varchar2(33) := '  pqp_pty_shd.';  -- Global package name
9 --
10 -- ----------------------------------------------------------------------------
11 -- |---------------------------< constraint_error >---------------------------|
12 -- ----------------------------------------------------------------------------
13 Procedure constraint_error
14   (p_constraint_name in all_constraints.constraint_name%TYPE
15   ) Is
16 --
17   l_proc        varchar2(72) := g_package||'constraint_error';
18 --
19 Begin
20   --
21   If (p_constraint_name = 'PQP_PENSION_TYPES_PK_F') Then
22     fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
23     fnd_message.set_token('PROCEDURE', l_proc);
24     fnd_message.set_token('STEP','5');
25     fnd_message.raise_error;
26   Else
27     fnd_message.set_name('PAY', 'HR_7877_API_INVALID_CONSTRAINT');
28     fnd_message.set_token('PROCEDURE', l_proc);
29     fnd_message.set_token('CONSTRAINT_NAME', p_constraint_name);
30     fnd_message.raise_error;
31   End If;
32   --
33 End constraint_error;
34 --
35 -- ----------------------------------------------------------------------------
36 -- |-----------------------------< api_updating >-----------------------------|
37 -- ----------------------------------------------------------------------------
38 Function api_updating
39   (p_effective_date                   in date
40   ,p_pension_type_id                  in number
41   ,p_object_version_number            in number
42   ) Return Boolean Is
43   --
44   -- Cursor selects the 'current' row from the HR Schema
45   --
46   Cursor C_Sel1 is
47     select
48      pension_type_id
49     ,effective_start_date
50     ,effective_end_date
51     ,pension_type_name
52     ,pension_category
53     ,pension_provider_type
54     ,salary_calculation_method
55     ,threshold_conversion_rule
56     ,contribution_conversion_rule
57     ,er_annual_limit
58     ,ee_annual_limit
59     ,er_annual_salary_threshold
60     ,ee_annual_salary_threshold
61     ,object_version_number
62     ,business_group_id
63     ,legislation_code
64     ,description
65     ,minimum_age
66     ,ee_contribution_percent
67     ,maximum_age
68     ,er_contribution_percent
69     ,ee_annual_contribution
70     ,er_annual_contribution
71     ,annual_premium_amount
72     ,ee_contribution_bal_type_id
73     ,er_contribution_bal_type_id
74     ,balance_init_element_type_id
75     ,ee_contribution_fixed_rate     -- added for UK
76     ,er_contribution_fixed_rate     -- added for UK
77     ,pty_attribute_category
78     ,pty_attribute1
79     ,pty_attribute2
80     ,pty_attribute3
81     ,pty_attribute4
82     ,pty_attribute5
83     ,pty_attribute6
84     ,pty_attribute7
85     ,pty_attribute8
86     ,pty_attribute9
87     ,pty_attribute10
88     ,pty_attribute11
89     ,pty_attribute12
90     ,pty_attribute13
91     ,pty_attribute14
92     ,pty_attribute15
93     ,pty_attribute16
94     ,pty_attribute17
95     ,pty_attribute18
96     ,pty_attribute19
97     ,pty_attribute20
98     ,pty_information_category
99     ,pty_information1
100     ,pty_information2
101     ,pty_information3
102     ,pty_information4
103     ,pty_information5
104     ,pty_information6
105     ,pty_information7
106     ,pty_information8
107     ,pty_information9
108     ,pty_information10
109     ,pty_information11
110     ,pty_information12
111     ,pty_information13
112     ,pty_information14
113     ,pty_information15
114     ,pty_information16
115     ,pty_information17
116     ,pty_information18
117     ,pty_information19
118     ,pty_information20
119     ,special_pension_type_code          -- added for NL Phase 2B
120     ,pension_sub_category               -- added for NL Phase 2B
121     ,pension_basis_calc_method          -- added for NL Phase 2B
122     ,pension_salary_balance             -- added for NL Phase 2B
123     ,recurring_bonus_percent            -- added for NL Phase 2B
124     ,non_recurring_bonus_percent        -- added for NL Phase 2B
125     ,recurring_bonus_balance            -- added for NL Phase 2B
126     ,non_recurring_bonus_balance        -- added for NL Phase 2B
127     ,std_tax_reduction                  -- added for NL Phase 2B
128     ,spl_tax_reduction                  -- added for NL Phase 2B
129     ,sig_sal_spl_tax_reduction          -- added for NL Phase 2B
130     ,sig_sal_non_tax_reduction          -- added for NL Phase 2B
131     ,sig_sal_std_tax_reduction          -- added for NL Phase 2B
132     ,sii_std_tax_reduction              -- added for NL Phase 2B
133     ,sii_spl_tax_reduction              -- added for NL Phase 2B
134     ,sii_non_tax_reduction              -- added for NL Phase 2B
135     ,previous_year_bonus_included       -- added for NL Phase 2B
136     ,recurring_bonus_period             -- added for NL Phase 2B
137     ,non_recurring_bonus_period         -- added for NL Phase 2B
138     ,ee_age_threshold                   -- added for ABP TAR fixes
139     ,er_age_threshold                   -- added for ABP TAR fixes
140     ,ee_age_contribution                -- added for ABP TAR fixes
141     ,er_age_contribution                -- added for ABP TAR fixes
142     from        pqp_pension_types_f
143     where       pension_type_id = p_pension_type_id
144     and         p_effective_date
145     between     effective_start_date and effective_end_date;
146 --
147   l_fct_ret     boolean;
148 --
149 Begin
150   --
151   If (p_effective_date is null or
152       p_pension_type_id is null or
153       p_object_version_number is null) Then
154     --
155     -- One of the primary key arguments is null therefore we must
156     -- set the returning function value to false
157     --
158     l_fct_ret := false;
159   Else
160     If (p_pension_type_id =
161         pqp_pty_shd.g_old_rec.pension_type_id and
162         p_object_version_number =
163         pqp_pty_shd.g_old_rec.object_version_number ) Then
164       --
165       -- The g_old_rec is current therefore we must
166       -- set the returning function to true
167       --
168       l_fct_ret := true;
169     Else
170       --
171       -- Select the current row
172       --
173       Open C_Sel1;
174       Fetch C_Sel1 Into pqp_pty_shd.g_old_rec;
175       If C_Sel1%notfound Then
176         Close C_Sel1;
177         --
178         -- The primary key is invalid therefore we must error
179         --
180         fnd_message.set_name('PAY', 'HR_7220_INVALID_PRIMARY_KEY');
181         fnd_message.raise_error;
182       End If;
183       Close C_Sel1;
184       If (p_object_version_number
185           <> pqp_pty_shd.g_old_rec.object_version_number) Then
186         fnd_message.set_name('PAY', 'HR_7155_OBJECT_INVALID');
187         fnd_message.raise_error;
188       End If;
189       l_fct_ret := true;
190     End If;
191   End If;
192   Return (l_fct_ret);
193 --
194 End api_updating;
195 --
196 -- ----------------------------------------------------------------------------
197 -- |---------------------------< find_dt_upd_modes >--------------------------|
198 -- ----------------------------------------------------------------------------
199 Procedure find_dt_upd_modes
200   (p_effective_date         in date
201   ,p_base_key_value         in number
202   ,p_correction             out nocopy boolean
203   ,p_update                 out nocopy boolean
204   ,p_update_override        out nocopy boolean
205   ,p_update_change_insert   out nocopy boolean
206   ) is
207 --
208   l_proc        varchar2(72) := g_package||'find_dt_upd_modes';
209 --
210 Begin
211   hr_utility.set_location('Entering:'||l_proc, 5);
212   --
213   -- Call the corresponding datetrack api
214   --
215   dt_api.find_dt_upd_modes
216     (p_effective_date        => p_effective_date
217     ,p_base_table_name       => 'pqp_pension_types_f'
218     ,p_base_key_column       => 'pension_type_id'
219     ,p_base_key_value        => p_base_key_value
220     ,p_correction            => p_correction
221     ,p_update                => p_update
222     ,p_update_override       => p_update_override
223     ,p_update_change_insert  => p_update_change_insert
224     );
225   --
226   hr_utility.set_location(' Leaving:'||l_proc, 10);
227 End find_dt_upd_modes;
228 --
229 -- ----------------------------------------------------------------------------
230 -- |---------------------------< find_dt_del_modes >--------------------------|
231 -- ----------------------------------------------------------------------------
232 Procedure find_dt_del_modes
233   (p_effective_date        in date
234   ,p_base_key_value        in number
235   ,p_zap                   out nocopy boolean
236   ,p_delete                out nocopy boolean
237   ,p_future_change         out nocopy boolean
238   ,p_delete_next_change    out nocopy boolean
239   ) is
240   --
241   l_proc                varchar2(72)    := g_package||'find_dt_del_modes';
242   --
243   --
244 Begin
245   hr_utility.set_location('Entering:'||l_proc, 5);
246   --
247   -- Call the corresponding datetrack api
248   --
249   dt_api.find_dt_del_modes
250    (p_effective_date                => p_effective_date
251    ,p_base_table_name               => 'pqp_pension_types_f'
252    ,p_base_key_column               => 'pension_type_id'
253    ,p_base_key_value                => p_base_key_value
254    ,p_zap                           => p_zap
255    ,p_delete                        => p_delete
256    ,p_future_change                 => p_future_change
257    ,p_delete_next_change            => p_delete_next_change
258    );
259   --
260   hr_utility.set_location(' Leaving:'||l_proc, 10);
261 End find_dt_del_modes;
262 --
263 -- ----------------------------------------------------------------------------
264 -- |-----------------------< upd_effective_end_date >-------------------------|
265 -- ----------------------------------------------------------------------------
266 Procedure upd_effective_end_date
267   (p_effective_date                   in date
268   ,p_base_key_value                   in number
269   ,p_new_effective_end_date           in date
270   ,p_validation_start_date            in date
271   ,p_validation_end_date              in date
272   ,p_object_version_number  out nocopy number
273   ) is
274 --
275   l_proc                  varchar2(72) := g_package||'upd_effective_end_date';
276   l_object_version_number number;
277 --
278 Begin
279   hr_utility.set_location('Entering:'||l_proc, 5);
280   --
281   -- Because we are updating a row we must get the next object
282   -- version number.
283   --
284   l_object_version_number :=
285     dt_api.get_object_version_number
286       (p_base_table_name    => 'pqp_pension_types_f'
287       ,p_base_key_column    => 'pension_type_id'
288       ,p_base_key_value     => p_base_key_value
289       );
290   --
291   hr_utility.set_location(l_proc, 10);
292   --
293 --
294   -- Update the specified datetrack row setting the effective
295   -- end date to the specified new effective end date.
296   --
297   update  pqp_pension_types_f t
298   set     t.effective_end_date    = p_new_effective_end_date
299     ,     t.object_version_number = l_object_version_number
300   where   t.pension_type_id        = p_base_key_value
301   and     p_effective_date
302   between t.effective_start_date and t.effective_end_date;
303   --
304   --
305   p_object_version_number := l_object_version_number;
306   hr_utility.set_location(' Leaving:'||l_proc, 15);
307 --
308 End upd_effective_end_date;
309 --
310 -- ----------------------------------------------------------------------------
311 -- |---------------------------------< lck >----------------------------------|
312 -- ----------------------------------------------------------------------------
313 Procedure lck
314   (p_effective_date                   in date
315   ,p_datetrack_mode                   in varchar2
316   ,p_pension_type_id                  in number
317   ,p_object_version_number            in number
318   ,p_validation_start_date            out nocopy date
319   ,p_validation_end_date              out nocopy date
320   ) is
321 --
322   l_proc                  varchar2(72) := g_package||'lck';
323   l_validation_start_date date;
324   l_validation_end_date   date;
325   l_argument              varchar2(30);
326   --
327   -- Cursor C_Sel1 selects the current locked row as of session date
328   -- ensuring that the object version numbers match.
329   --
330   Cursor C_Sel1 is
331     select
332      pension_type_id
333     ,effective_start_date
334     ,effective_end_date
335     ,pension_type_name
336     ,pension_category
337     ,pension_provider_type
338     ,salary_calculation_method
339     ,threshold_conversion_rule
340     ,contribution_conversion_rule
341     ,er_annual_limit
342     ,ee_annual_limit
343     ,er_annual_salary_threshold
344     ,ee_annual_salary_threshold
345     ,object_version_number
346     ,business_group_id
347     ,legislation_code
348     ,description
349     ,minimum_age
350     ,ee_contribution_percent
351     ,maximum_age
352     ,er_contribution_percent
353     ,ee_annual_contribution
354     ,er_annual_contribution
355     ,annual_premium_amount
356     ,ee_contribution_bal_type_id
357     ,er_contribution_bal_type_id
358     ,balance_init_element_type_id
359     ,ee_contribution_fixed_rate   -- added for UK
360     ,er_contribution_fixed_rate   -- added for UK
361     ,pty_attribute_category
362     ,pty_attribute1
363     ,pty_attribute2
364     ,pty_attribute3
365     ,pty_attribute4
366     ,pty_attribute5
367     ,pty_attribute6
368     ,pty_attribute7
369     ,pty_attribute8
370     ,pty_attribute9
371     ,pty_attribute10
372     ,pty_attribute11
373     ,pty_attribute12
374     ,pty_attribute13
378     ,pty_attribute17
375     ,pty_attribute14
376     ,pty_attribute15
377     ,pty_attribute16
379     ,pty_attribute18
380     ,pty_attribute19
381     ,pty_attribute20
382     ,pty_information_category
383     ,pty_information1
384     ,pty_information2
385     ,pty_information3
386     ,pty_information4
387     ,pty_information5
388     ,pty_information6
389     ,pty_information7
390     ,pty_information8
391     ,pty_information9
392     ,pty_information10
393     ,pty_information11
394     ,pty_information12
395     ,pty_information13
396     ,pty_information14
397     ,pty_information15
398     ,pty_information16
399     ,pty_information17
400     ,pty_information18
401     ,pty_information19
402     ,pty_information20
403     ,special_pension_type_code          -- added for NL Phase 2B
404     ,pension_sub_category               -- added for NL Phase 2B
405     ,pension_basis_calc_method          -- added for NL Phase 2B
406     ,pension_salary_balance             -- added for NL Phase 2B
407     ,recurring_bonus_percent            -- added for NL Phase 2B
408     ,non_recurring_bonus_percent        -- added for NL Phase 2B
409     ,recurring_bonus_balance            -- added for NL Phase 2B
410     ,non_recurring_bonus_balance        -- added for NL Phase 2B
411     ,std_tax_reduction                  -- added for NL Phase 2B
412     ,spl_tax_reduction                  -- added for NL Phase 2B
413     ,sig_sal_spl_tax_reduction          -- added for NL Phase 2B
414     ,sig_sal_non_tax_reduction          -- added for NL Phase 2B
415     ,sig_sal_std_tax_reduction          -- added for NL Phase 2B
416     ,sii_std_tax_reduction              -- added for NL Phase 2B
417     ,sii_spl_tax_reduction              -- added for NL Phase 2B
418     ,sii_non_tax_reduction              -- added for NL Phase 2B
419     ,previous_year_bonus_included       -- added for NL Phase 2B
420     ,recurring_bonus_period             -- added for NL Phase 2B
421     ,non_recurring_bonus_period         -- added for NL Phase 2B
422     ,ee_age_threshold                   -- added for ABP TAR fixes
423     ,er_age_threshold                   -- added for ABP TAR fixes
424     ,ee_age_contribution                -- added for ABP TAR fixes
425     ,er_age_contribution                -- added for ABP TAR fixes
426     from    pqp_pension_types_f
427     where   pension_type_id = p_pension_type_id
428     and     p_effective_date
429     between effective_start_date and effective_end_date
430     for update nowait;
431   --
432   --
433   --
434 Begin
435   hr_utility.set_location('Entering:'||l_proc, 5);
436   --
437   -- Ensure that all the mandatory arguments are not null
438   --
439   hr_api.mandatory_arg_error(p_api_name       => l_proc
440                             ,p_argument       => 'effective_date'
441                             ,p_argument_value => p_effective_date
442                             );
443   --
444   hr_api.mandatory_arg_error(p_api_name       => l_proc
445                             ,p_argument       => 'datetrack_mode'
446                             ,p_argument_value => p_datetrack_mode
447                             );
448   --
449   hr_api.mandatory_arg_error(p_api_name       => l_proc
450                             ,p_argument       => 'pension_type_id'
451                             ,p_argument_value => p_pension_type_id
452                             );
453   --
454     hr_api.mandatory_arg_error(p_api_name       => l_proc
455                             ,p_argument       => 'object_version_number'
456                             ,p_argument_value => p_object_version_number
457                             );
458   --
459   -- Check to ensure the datetrack mode is not INSERT.
460   --
461   If (p_datetrack_mode <> hr_api.g_insert) then
462     --
463     -- We must select and lock the current row.
464     --
465     Open  C_Sel1;
466     Fetch C_Sel1 Into pqp_pty_shd.g_old_rec;
467     If C_Sel1%notfound then
468       Close C_Sel1;
469       --
470       -- The primary key is invalid therefore we must error
471       --
472       fnd_message.set_name('PAY', 'HR_7220_INVALID_PRIMARY_KEY');
473       fnd_message.raise_error;
474     End If;
475     Close C_Sel1;
476     If (p_object_version_number
477           <> pqp_pty_shd.g_old_rec.object_version_number) Then
478         fnd_message.set_name('PAY', 'HR_7155_OBJECT_INVALID');
479         fnd_message.raise_error;
480     End If;
481     --
482     --
483     -- Validate the datetrack mode mode getting the validation start
484     -- and end dates for the specified datetrack operation.
485     --
486     dt_api.validate_dt_mode
487       (p_effective_date          => p_effective_date
488       ,p_datetrack_mode          => p_datetrack_mode
489       ,p_base_table_name         => 'pqp_pension_types_f'
490       ,p_base_key_column         => 'pension_type_id'
491       ,p_base_key_value          => p_pension_type_id
492       ,p_enforce_foreign_locking => true
493       ,p_validation_start_date   => l_validation_start_date
494       ,p_validation_end_date     => l_validation_end_date
495       );
496   Else
497     --
498     -- We are doing a datetrack 'INSERT' which is illegal within this
499     -- procedure therefore we must error (note: to lck on insert the
503     fnd_message.set_token('PROCEDURE', l_proc);
500     -- private procedure ins_lck should be called).
501     --
502     fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
504     fnd_message.set_token('STEP','20');
505     fnd_message.raise_error;
506   End If;
507   --
508   -- Set the validation start and end date OUT arguments
509   --
510   p_validation_start_date := l_validation_start_date;
511   p_validation_end_date   := l_validation_end_date;
512   --
513   hr_utility.set_location(' Leaving:'||l_proc, 30);
514 --
515 -- We need to trap the ORA LOCK exception
516 --
517 Exception
518   When HR_Api.Object_Locked then
519     --
520     -- The object is locked therefore we need to supply a meaningful
521     -- error message.
522     --
523     fnd_message.set_name('PAY', 'HR_7165_OBJECT_LOCKED');
524     fnd_message.set_token('TABLE_NAME', 'pqp_pension_types_f');
525     fnd_message.raise_error;
526 End lck;
527 --
528 -- ----------------------------------------------------------------------------
529 -- |-----------------------------< convert_args >-----------------------------|
530 -- ----------------------------------------------------------------------------
531 Function convert_args
532   (p_pension_type_id                in number
533   ,p_effective_start_date           in date
534   ,p_effective_end_date             in date
535   ,p_pension_type_name              in varchar2
536   ,p_pension_category               in varchar2
537   ,p_pension_provider_type          in varchar2
538   ,p_salary_calculation_method      in varchar2
539   ,p_threshold_conversion_rule      in varchar2
540   ,p_contribution_conversion_rule   in varchar2
541   ,p_er_annual_limit                in number
542   ,p_ee_annual_limit                in number
543   ,p_er_annual_salary_threshold     in number
544   ,p_ee_annual_salary_threshold     in number
545   ,p_object_version_number          in number
546   ,p_business_group_id              in number
547   ,p_legislation_code               in varchar2
548   ,p_description                    in varchar2
549   ,p_minimum_age                    in number
550   ,p_ee_contribution_percent        in number
551   ,p_maximum_age                    in number
552   ,p_er_contribution_percent        in number
553   ,p_ee_annual_contribution         in number
554   ,p_er_annual_contribution         in number
555   ,p_annual_premium_amount          in number
556   ,p_ee_contribution_bal_type_id    in number
557   ,p_er_contribution_bal_type_id    in number
558   ,p_balance_init_element_type_id   in number
559   ,p_ee_contribution_fixed_rate     in number    --added for UK
560   ,p_er_contribution_fixed_rate     in number    --added for UK
561   ,p_pty_attribute_category         in varchar2
562   ,p_pty_attribute1                 in varchar2
563   ,p_pty_attribute2                 in varchar2
564   ,p_pty_attribute3                 in varchar2
565   ,p_pty_attribute4                 in varchar2
566   ,p_pty_attribute5                 in varchar2
567   ,p_pty_attribute6                 in varchar2
568   ,p_pty_attribute7                 in varchar2
569   ,p_pty_attribute8                 in varchar2
570   ,p_pty_attribute9                 in varchar2
571   ,p_pty_attribute10                in varchar2
572   ,p_pty_attribute11                in varchar2
573   ,p_pty_attribute12                in varchar2
574   ,p_pty_attribute13                in varchar2
575   ,p_pty_attribute14                in varchar2
576   ,p_pty_attribute15                in varchar2
577   ,p_pty_attribute16                in varchar2
578   ,p_pty_attribute17                in varchar2
579   ,p_pty_attribute18                in varchar2
580   ,p_pty_attribute19                in varchar2
581   ,p_pty_attribute20                in varchar2
582   ,p_pty_information_category       in varchar2
583   ,p_pty_information1               in varchar2
584   ,p_pty_information2               in varchar2
585   ,p_pty_information3               in varchar2
586   ,p_pty_information4               in varchar2
587   ,p_pty_information5               in varchar2
588   ,p_pty_information6               in varchar2
589   ,p_pty_information7               in varchar2
590   ,p_pty_information8               in varchar2
591   ,p_pty_information9               in varchar2
592   ,p_pty_information10              in varchar2
593   ,p_pty_information11              in varchar2
594   ,p_pty_information12              in varchar2
595   ,p_pty_information13              in varchar2
596   ,p_pty_information14              in varchar2
597   ,p_pty_information15              in varchar2
598   ,p_pty_information16              in varchar2
599   ,p_pty_information17              in varchar2
600   ,p_pty_information18              in varchar2
601   ,p_pty_information19              in varchar2
602   ,p_pty_information20              in varchar2
603   ,p_special_pension_type_code      in varchar2    -- added for NL Phase 2B
604   ,p_pension_sub_category           in varchar2    -- added for NL Phase 2B
605   ,p_pension_basis_calc_method      in varchar2    -- added for NL Phase 2B
606   ,p_pension_salary_balance         in number      -- added for NL Phase 2B
607   ,p_recurring_bonus_percent        in number      -- added for NL Phase 2B
608   ,p_non_recurring_bonus_percent    in number      -- added for NL Phase 2B
609   ,p_recurring_bonus_balance        in number      -- added for NL Phase 2B
613   ,p_sig_sal_spl_tax_reduction      in varchar2    -- added for NL Phase 2B
610   ,p_non_recurring_bonus_balance    in number      -- added for NL Phase 2B
611   ,p_std_tax_reduction              in varchar2    -- added for NL Phase 2B
612   ,p_spl_tax_reduction              in varchar2    -- added for NL Phase 2B
614   ,p_sig_sal_non_tax_reduction      in varchar2    -- added for NL Phase 2B
615   ,p_sig_sal_std_tax_reduction      in varchar2    -- added for NL Phase 2B
616   ,p_sii_std_tax_reduction          in varchar2    -- added for NL Phase 2B
617   ,p_sii_spl_tax_reduction          in varchar2    -- added for NL Phase 2B
618   ,p_sii_non_tax_reduction          in varchar2    -- added for NL Phase 2B
619   ,p_previous_year_bonus_included   in varchar2    -- added for NL Phase 2B
620   ,p_recurring_bonus_period         in varchar2    -- added for NL Phase 2B
621   ,p_non_recurring_bonus_period     in varchar2    -- added for NL Phase 2B
622   ,p_ee_age_threshold               in varchar2    -- added for ABP TAR fixes
623   ,p_er_age_threshold               in varchar2    -- added for ABP TAR fixes
624   ,p_ee_age_contribution            in varchar2    -- added for ABP TAR fixes
625   ,p_er_age_contribution            in varchar2    -- added for ABP TAR fixes
626   )
627   Return g_rec_type is
628 --
629   l_rec   g_rec_type;
630 --
631 Begin
632   --
633   -- Convert arguments into local l_rec structure.
634   --
635   l_rec.pension_type_id                  := p_pension_type_id;
636   l_rec.effective_start_date             := p_effective_start_date;
637   l_rec.effective_end_date               := p_effective_end_date;
638   l_rec.pension_type_name                := p_pension_type_name;
639   l_rec.pension_category                 := p_pension_category;
640   l_rec.pension_provider_type            := p_pension_provider_type;
641   l_rec.salary_calculation_method        := p_salary_calculation_method;
642   l_rec.threshold_conversion_rule        := p_threshold_conversion_rule;
643   l_rec.contribution_conversion_rule     := p_contribution_conversion_rule;
644   l_rec.er_annual_limit                  := p_er_annual_limit;
645   l_rec.ee_annual_limit                  := p_ee_annual_limit;
646   l_rec.er_annual_salary_threshold       := p_er_annual_salary_threshold;
647   l_rec.ee_annual_salary_threshold       := p_ee_annual_salary_threshold;
648   l_rec.object_version_number            := p_object_version_number;
649   l_rec.business_group_id                := p_business_group_id;
650   l_rec.legislation_code                 := p_legislation_code;
651   l_rec.description                      := p_description;
652   l_rec.minimum_age                      := p_minimum_age;
653   l_rec.ee_contribution_percent          := p_ee_contribution_percent;
654   l_rec.maximum_age                      := p_maximum_age;
655   l_rec.er_contribution_percent          := p_er_contribution_percent;
656   l_rec.ee_annual_contribution           := p_ee_annual_contribution;
657   l_rec.er_annual_contribution           := p_er_annual_contribution;
658   l_rec.annual_premium_amount            := p_annual_premium_amount;
659   l_rec.ee_contribution_bal_type_id      := p_ee_contribution_bal_type_id;
660   l_rec.er_contribution_bal_type_id      := p_er_contribution_bal_type_id;
661   l_rec.balance_init_element_type_id     := p_balance_init_element_type_id;
662   l_rec.ee_contribution_fixed_rate     := p_ee_contribution_fixed_rate ; -- added for UK
663   l_rec.er_contribution_fixed_rate     := p_er_contribution_fixed_rate ;  -- added for UK
664   l_rec.pty_attribute_category           := p_pty_attribute_category;
665   l_rec.pty_attribute1                   := p_pty_attribute1;
666   l_rec.pty_attribute2                   := p_pty_attribute2;
667   l_rec.pty_attribute3                   := p_pty_attribute3;
668   l_rec.pty_attribute4                   := p_pty_attribute4;
669   l_rec.pty_attribute5                   := p_pty_attribute5;
670   l_rec.pty_attribute6                   := p_pty_attribute6;
671   l_rec.pty_attribute7                   := p_pty_attribute7;
672   l_rec.pty_attribute8                   := p_pty_attribute8;
673   l_rec.pty_attribute9                   := p_pty_attribute9;
674   l_rec.pty_attribute10                  := p_pty_attribute10;
675   l_rec.pty_attribute11                  := p_pty_attribute11;
676   l_rec.pty_attribute12                  := p_pty_attribute12;
677   l_rec.pty_attribute13                  := p_pty_attribute13;
678   l_rec.pty_attribute14                  := p_pty_attribute14;
679   l_rec.pty_attribute15                  := p_pty_attribute15;
680   l_rec.pty_attribute16                  := p_pty_attribute16;
681   l_rec.pty_attribute17                  := p_pty_attribute17;
682   l_rec.pty_attribute18                  := p_pty_attribute18;
683   l_rec.pty_attribute19                  := p_pty_attribute19;
684   l_rec.pty_attribute20                  := p_pty_attribute20;
685   l_rec.pty_information_category         := p_pty_information_category;
686   l_rec.pty_information1                 := p_pty_information1;
687   l_rec.pty_information2                 := p_pty_information2;
688   l_rec.pty_information3                 := p_pty_information3;
689   l_rec.pty_information4                 := p_pty_information4;
690   l_rec.pty_information5                 := p_pty_information5;
691   l_rec.pty_information6                 := p_pty_information6;
692   l_rec.pty_information7                 := p_pty_information7;
693   l_rec.pty_information8                 := p_pty_information8;
694   l_rec.pty_information9                 := p_pty_information9;
695   l_rec.pty_information10                := p_pty_information10;
696   l_rec.pty_information11                := p_pty_information11;
697   l_rec.pty_information12                := p_pty_information12;
701   l_rec.pty_information16                := p_pty_information16;
698   l_rec.pty_information13                := p_pty_information13;
699   l_rec.pty_information14                := p_pty_information14;
700   l_rec.pty_information15                := p_pty_information15;
702   l_rec.pty_information17                := p_pty_information17;
703   l_rec.pty_information18                := p_pty_information18;
704   l_rec.pty_information19                := p_pty_information19;
705   l_rec.pty_information20                := p_pty_information20;
706   l_rec.special_pension_type_code        := p_special_pension_type_code;        -- added for NL Phase 2B
707   l_rec.pension_sub_category         	 := p_pension_sub_category;             -- added for NL Phase 2B
708   l_rec.pension_basis_calc_method    	 := p_pension_basis_calc_method;        -- added for NL Phase 2B
709   l_rec.pension_salary_balance       	 := p_pension_salary_balance ;          -- added for NL Phase 2B
710   l_rec.recurring_bonus_percent      	 := p_recurring_bonus_percent ;         -- added for NL Phase 2B
711   l_rec.non_recurring_bonus_percent  	 := p_non_recurring_bonus_percent ;     -- added for NL Phase 2B
712   l_rec.recurring_bonus_balance      	 := p_recurring_bonus_balance  ;        -- added for NL Phase 2B
713   l_rec.non_recurring_bonus_balance  	 := p_non_recurring_bonus_balance;      -- added for NL Phase 2B
714   l_rec.std_tax_reduction            	 := p_std_tax_reduction;                -- added for NL Phase 2B
715   l_rec.spl_tax_reduction            	 := p_spl_tax_reduction;                -- added for NL Phase 2B
716   l_rec.sig_sal_spl_tax_reduction    	 := p_sig_sal_spl_tax_reduction;        -- added for NL Phase 2B
717   l_rec.sig_sal_non_tax_reduction    	 := p_sig_sal_non_tax_reduction ;       -- added for NL Phase 2B
718   l_rec.sig_sal_std_tax_reduction    	 := p_sig_sal_std_tax_reduction;        -- added for NL Phase 2B
719   l_rec.sii_std_tax_reduction        	 := p_sii_std_tax_reduction;            -- added for NL Phase 2B
720   l_rec.sii_spl_tax_reduction        	 := p_sii_spl_tax_reduction;            -- added for NL Phase 2B
721   l_rec.sii_non_tax_reduction        	 := p_sii_non_tax_reduction ;           -- added for NL Phase 2B
722   l_rec.previous_year_bonus_included 	 := p_previous_year_bonus_included;     -- added for NL Phase 2B
723   l_rec.recurring_bonus_period   	 := p_recurring_bonus_period;           -- added for NL Phase 2B
724   l_rec.non_recurring_bonus_period 	 := p_non_recurring_bonus_period;      -- added for NL Phase 2B
725   l_rec.ee_age_threshold                 := p_ee_age_threshold;                 -- added for ABP TAR fixes
726   l_rec.er_age_threshold                 := p_er_age_threshold;                 -- added for ABP TAR fixes
727   l_rec.ee_age_contribution              := p_ee_age_contribution;              -- added for ABP TAR fixes
728   l_rec.er_age_contribution              := p_er_age_contribution;              -- added for ABP TAR fixes
729   --
730   -- Return the plsql record structure.
731   --
732   Return(l_rec);
733 --
734 End convert_args;
735 --
736 
737 
738 end pqp_pty_shd;
739