66: --
67: Begin
68: hr_utility.set_location('Entering:'||l_proc, 5);
69: --
70: If (p_datetrack_mode = hr_api.g_correction) then
71: hr_utility.set_location(l_proc, 10);
72: --
73: -- Because we are updating a row we must get the next object
74: -- version number.
115: End If;
116: --
117: hr_utility.set_location(' Leaving:'||l_proc, 15);
118: Exception
119: When hr_api.check_integrity_violated Then
120: -- A check constraint has been violated
121: pay_pgr_shd.g_api_dml := false; -- Unset the api dml status
122: pay_pgr_shd.constraint_error
123: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
119: When hr_api.check_integrity_violated Then
120: -- A check constraint has been violated
121: pay_pgr_shd.g_api_dml := false; -- Unset the api dml status
122: pay_pgr_shd.constraint_error
123: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
124: When hr_api.unique_integrity_violated Then
125: -- Unique integrity has been violated
126: pay_pgr_shd.g_api_dml := false; -- Unset the api dml status
127: pay_pgr_shd.constraint_error
120: -- A check constraint has been violated
121: pay_pgr_shd.g_api_dml := false; -- Unset the api dml status
122: pay_pgr_shd.constraint_error
123: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
124: When hr_api.unique_integrity_violated Then
125: -- Unique integrity has been violated
126: pay_pgr_shd.g_api_dml := false; -- Unset the api dml status
127: pay_pgr_shd.constraint_error
128: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
124: When hr_api.unique_integrity_violated Then
125: -- Unique integrity has been violated
126: pay_pgr_shd.g_api_dml := false; -- Unset the api dml status
127: pay_pgr_shd.constraint_error
128: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
129: When Others Then
130: pay_pgr_shd.g_api_dml := false; -- Unset the api dml status
131: Raise;
132: End dt_update_dml;
241: l_dummy_version_number number;
242: --
243: Begin
244: hr_utility.set_location('Entering:'||l_proc, 5);
245: If (p_datetrack_mode <> hr_api.g_correction) then
246: --
247: -- Update the current effective end date
248: --
249: pay_pgr_shd.upd_effective_end_date
254: ,p_validation_end_date => p_validation_end_date
255: ,p_object_version_number => l_dummy_version_number
256: );
257: --
258: If (p_datetrack_mode = hr_api.g_update_override) then
259: --
260: -- As the datetrack mode is 'UPDATE_OVERRIDE' then we must
261: -- delete any future rows
262: --
468: );
469: --
470: exception
471: --
472: when hr_api.cannot_find_prog_unit then
473: --
474: hr_api.cannot_find_prog_unit_error
475: (p_module_name => 'PAY_GRADE_RULES_F'
476: ,p_hook_type => 'AU');
470: exception
471: --
472: when hr_api.cannot_find_prog_unit then
473: --
474: hr_api.cannot_find_prog_unit_error
475: (p_module_name => 'PAY_GRADE_RULES_F'
476: ,p_hook_type => 'AU');
477: --
478: end;
533: -- p_rec plsql record structure
534: -- to see if a system default is being used. If a system default
535: -- is being used then we must set to the 'current' argument value.
536: --
537: If (p_rec.business_group_id = hr_api.g_number) then
538: p_rec.business_group_id :=
539: pay_pgr_shd.g_old_rec.business_group_id;
540: End If;
541: If (p_rec.rate_id = hr_api.g_number) then
537: If (p_rec.business_group_id = hr_api.g_number) then
538: p_rec.business_group_id :=
539: pay_pgr_shd.g_old_rec.business_group_id;
540: End If;
541: If (p_rec.rate_id = hr_api.g_number) then
542: p_rec.rate_id :=
543: pay_pgr_shd.g_old_rec.rate_id;
544: End If;
545: If (p_rec.grade_or_spinal_point_id = hr_api.g_number) then
541: If (p_rec.rate_id = hr_api.g_number) then
542: p_rec.rate_id :=
543: pay_pgr_shd.g_old_rec.rate_id;
544: End If;
545: If (p_rec.grade_or_spinal_point_id = hr_api.g_number) then
546: p_rec.grade_or_spinal_point_id :=
547: pay_pgr_shd.g_old_rec.grade_or_spinal_point_id;
548: End If;
549: If (p_rec.rate_type = hr_api.g_varchar2) then
545: If (p_rec.grade_or_spinal_point_id = hr_api.g_number) then
546: p_rec.grade_or_spinal_point_id :=
547: pay_pgr_shd.g_old_rec.grade_or_spinal_point_id;
548: End If;
549: If (p_rec.rate_type = hr_api.g_varchar2) then
550: p_rec.rate_type :=
551: pay_pgr_shd.g_old_rec.rate_type;
552: End If;
553: If (p_rec.maximum = hr_api.g_varchar2) then
549: If (p_rec.rate_type = hr_api.g_varchar2) then
550: p_rec.rate_type :=
551: pay_pgr_shd.g_old_rec.rate_type;
552: End If;
553: If (p_rec.maximum = hr_api.g_varchar2) then
554: p_rec.maximum :=
555: pay_pgr_shd.g_old_rec.maximum;
556: End If;
557: If (p_rec.mid_value = hr_api.g_varchar2) then
553: If (p_rec.maximum = hr_api.g_varchar2) then
554: p_rec.maximum :=
555: pay_pgr_shd.g_old_rec.maximum;
556: End If;
557: If (p_rec.mid_value = hr_api.g_varchar2) then
558: p_rec.mid_value :=
559: pay_pgr_shd.g_old_rec.mid_value;
560: End If;
561: If (p_rec.minimum = hr_api.g_varchar2) then
557: If (p_rec.mid_value = hr_api.g_varchar2) then
558: p_rec.mid_value :=
559: pay_pgr_shd.g_old_rec.mid_value;
560: End If;
561: If (p_rec.minimum = hr_api.g_varchar2) then
562: p_rec.minimum :=
563: pay_pgr_shd.g_old_rec.minimum;
564: End If;
565: If (p_rec.value = hr_api.g_varchar2) then
561: If (p_rec.minimum = hr_api.g_varchar2) then
562: p_rec.minimum :=
563: pay_pgr_shd.g_old_rec.minimum;
564: End If;
565: If (p_rec.value = hr_api.g_varchar2) then
566: p_rec.value :=
567: pay_pgr_shd.g_old_rec.value;
568: End If;
569: If (p_rec.sequence = hr_api.g_number) then
565: If (p_rec.value = hr_api.g_varchar2) then
566: p_rec.value :=
567: pay_pgr_shd.g_old_rec.value;
568: End If;
569: If (p_rec.sequence = hr_api.g_number) then
570: p_rec.sequence :=
571: pay_pgr_shd.g_old_rec.sequence;
572: End If;
573: If (p_rec.request_id = hr_api.g_number) then
569: If (p_rec.sequence = hr_api.g_number) then
570: p_rec.sequence :=
571: pay_pgr_shd.g_old_rec.sequence;
572: End If;
573: If (p_rec.request_id = hr_api.g_number) then
574: p_rec.request_id :=
575: pay_pgr_shd.g_old_rec.request_id;
576: End If;
577: If (p_rec.program_application_id = hr_api.g_number) then
573: If (p_rec.request_id = hr_api.g_number) then
574: p_rec.request_id :=
575: pay_pgr_shd.g_old_rec.request_id;
576: End If;
577: If (p_rec.program_application_id = hr_api.g_number) then
578: p_rec.program_application_id :=
579: pay_pgr_shd.g_old_rec.program_application_id;
580: End If;
581: If (p_rec.program_id = hr_api.g_number) then
577: If (p_rec.program_application_id = hr_api.g_number) then
578: p_rec.program_application_id :=
579: pay_pgr_shd.g_old_rec.program_application_id;
580: End If;
581: If (p_rec.program_id = hr_api.g_number) then
582: p_rec.program_id :=
583: pay_pgr_shd.g_old_rec.program_id;
584: End If;
585: If (p_rec.program_update_date = hr_api.g_date) then
581: If (p_rec.program_id = hr_api.g_number) then
582: p_rec.program_id :=
583: pay_pgr_shd.g_old_rec.program_id;
584: End If;
585: If (p_rec.program_update_date = hr_api.g_date) then
586: p_rec.program_update_date :=
587: pay_pgr_shd.g_old_rec.program_update_date;
588: End If;
589: If (p_rec.currency_code = hr_api.g_varchar2) then
585: If (p_rec.program_update_date = hr_api.g_date) then
586: p_rec.program_update_date :=
587: pay_pgr_shd.g_old_rec.program_update_date;
588: End If;
589: If (p_rec.currency_code = hr_api.g_varchar2) then
590: p_rec.currency_code :=
591: pay_pgr_shd.g_old_rec.currency_code;
592: End If;
593: --
684: (p_effective_date in date
685: ,p_datetrack_mode in varchar2
686: ,p_grade_rule_id in number
687: ,p_object_version_number in out nocopy number
688: ,p_maximum in varchar2 default hr_api.g_varchar2
689: ,p_mid_value in varchar2 default hr_api.g_varchar2
690: ,p_minimum in varchar2 default hr_api.g_varchar2
691: ,p_sequence in number default hr_api.g_number
692: ,p_value in varchar2 default hr_api.g_varchar2
685: ,p_datetrack_mode in varchar2
686: ,p_grade_rule_id in number
687: ,p_object_version_number in out nocopy number
688: ,p_maximum in varchar2 default hr_api.g_varchar2
689: ,p_mid_value in varchar2 default hr_api.g_varchar2
690: ,p_minimum in varchar2 default hr_api.g_varchar2
691: ,p_sequence in number default hr_api.g_number
692: ,p_value in varchar2 default hr_api.g_varchar2
693: ,p_currency_code in varchar2 default hr_api.g_varchar2
686: ,p_grade_rule_id in number
687: ,p_object_version_number in out nocopy number
688: ,p_maximum in varchar2 default hr_api.g_varchar2
689: ,p_mid_value in varchar2 default hr_api.g_varchar2
690: ,p_minimum in varchar2 default hr_api.g_varchar2
691: ,p_sequence in number default hr_api.g_number
692: ,p_value in varchar2 default hr_api.g_varchar2
693: ,p_currency_code in varchar2 default hr_api.g_varchar2
694: ,p_effective_start_date out nocopy date
687: ,p_object_version_number in out nocopy number
688: ,p_maximum in varchar2 default hr_api.g_varchar2
689: ,p_mid_value in varchar2 default hr_api.g_varchar2
690: ,p_minimum in varchar2 default hr_api.g_varchar2
691: ,p_sequence in number default hr_api.g_number
692: ,p_value in varchar2 default hr_api.g_varchar2
693: ,p_currency_code in varchar2 default hr_api.g_varchar2
694: ,p_effective_start_date out nocopy date
695: ,p_effective_end_date out nocopy date
688: ,p_maximum in varchar2 default hr_api.g_varchar2
689: ,p_mid_value in varchar2 default hr_api.g_varchar2
690: ,p_minimum in varchar2 default hr_api.g_varchar2
691: ,p_sequence in number default hr_api.g_number
692: ,p_value in varchar2 default hr_api.g_varchar2
693: ,p_currency_code in varchar2 default hr_api.g_varchar2
694: ,p_effective_start_date out nocopy date
695: ,p_effective_end_date out nocopy date
696: ) is
689: ,p_mid_value in varchar2 default hr_api.g_varchar2
690: ,p_minimum in varchar2 default hr_api.g_varchar2
691: ,p_sequence in number default hr_api.g_number
692: ,p_value in varchar2 default hr_api.g_varchar2
693: ,p_currency_code in varchar2 default hr_api.g_varchar2
694: ,p_effective_start_date out nocopy date
695: ,p_effective_end_date out nocopy date
696: ) is
697: --
708: pay_pgr_shd.convert_args
709: (p_grade_rule_id
710: ,NULL
711: ,NULL
712: ,hr_api.g_number --p_business_group_id
713: ,hr_api.g_number --p_rate_id
714: ,hr_api.g_number --p_grade_or_spinal_point_id
715: ,hr_api.g_varchar2 --p_rate_type
716: ,p_maximum
709: (p_grade_rule_id
710: ,NULL
711: ,NULL
712: ,hr_api.g_number --p_business_group_id
713: ,hr_api.g_number --p_rate_id
714: ,hr_api.g_number --p_grade_or_spinal_point_id
715: ,hr_api.g_varchar2 --p_rate_type
716: ,p_maximum
717: ,p_mid_value
710: ,NULL
711: ,NULL
712: ,hr_api.g_number --p_business_group_id
713: ,hr_api.g_number --p_rate_id
714: ,hr_api.g_number --p_grade_or_spinal_point_id
715: ,hr_api.g_varchar2 --p_rate_type
716: ,p_maximum
717: ,p_mid_value
718: ,p_minimum
711: ,NULL
712: ,hr_api.g_number --p_business_group_id
713: ,hr_api.g_number --p_rate_id
714: ,hr_api.g_number --p_grade_or_spinal_point_id
715: ,hr_api.g_varchar2 --p_rate_type
716: ,p_maximum
717: ,p_mid_value
718: ,p_minimum
719: ,p_sequence