51: --
52: -- {End Of Comments}
53: -- ----------------------------------------------------------------------------
54: Procedure update_dml
55: (p_rec in out nocopy pay_peu_shd.g_rec_type
56: ) is
57: --
58: l_proc varchar2(72) := g_package||'update_dml';
59: --
62: --
63: -- Increment the object version
64: p_rec.object_version_number := p_rec.object_version_number + 1;
65: --
66: pay_peu_shd.g_api_dml := true; -- Set the api dml status
67: --
68: -- Update the pay_event_updates Row
69: --
70: update pay_event_updates
79: ,event_type = p_rec.event_type
80: ,object_version_number = p_rec.object_version_number
81: where event_update_id = p_rec.event_update_id;
82: --
83: pay_peu_shd.g_api_dml := false; -- Unset the api dml status
84: --
85: hr_utility.set_location(' Leaving:'||l_proc, 10);
86: --
87: Exception
86: --
87: Exception
88: When hr_api.check_integrity_violated Then
89: -- A check constraint has been violated
90: pay_peu_shd.g_api_dml := false; -- Unset the api dml status
91: pay_peu_shd.constraint_error
92: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
93: When hr_api.parent_integrity_violated Then
94: -- Parent integrity has been violated
87: Exception
88: When hr_api.check_integrity_violated Then
89: -- A check constraint has been violated
90: pay_peu_shd.g_api_dml := false; -- Unset the api dml status
91: pay_peu_shd.constraint_error
92: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
93: When hr_api.parent_integrity_violated Then
94: -- Parent integrity has been violated
95: pay_peu_shd.g_api_dml := false; -- Unset the api dml status
91: pay_peu_shd.constraint_error
92: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
93: When hr_api.parent_integrity_violated Then
94: -- Parent integrity has been violated
95: pay_peu_shd.g_api_dml := false; -- Unset the api dml status
96: pay_peu_shd.constraint_error
97: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
98: When hr_api.unique_integrity_violated Then
99: -- Unique integrity has been violated
92: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
93: When hr_api.parent_integrity_violated Then
94: -- Parent integrity has been violated
95: pay_peu_shd.g_api_dml := false; -- Unset the api dml status
96: pay_peu_shd.constraint_error
97: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
98: When hr_api.unique_integrity_violated Then
99: -- Unique integrity has been violated
100: pay_peu_shd.g_api_dml := false; -- Unset the api dml status
96: pay_peu_shd.constraint_error
97: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
98: When hr_api.unique_integrity_violated Then
99: -- Unique integrity has been violated
100: pay_peu_shd.g_api_dml := false; -- Unset the api dml status
101: pay_peu_shd.constraint_error
102: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
103: When Others Then
104: pay_peu_shd.g_api_dml := false; -- Unset the api dml status
97: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
98: When hr_api.unique_integrity_violated Then
99: -- Unique integrity has been violated
100: pay_peu_shd.g_api_dml := false; -- Unset the api dml status
101: pay_peu_shd.constraint_error
102: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
103: When Others Then
104: pay_peu_shd.g_api_dml := false; -- Unset the api dml status
105: Raise;
100: pay_peu_shd.g_api_dml := false; -- Unset the api dml status
101: pay_peu_shd.constraint_error
102: (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
103: When Others Then
104: pay_peu_shd.g_api_dml := false; -- Unset the api dml status
105: Raise;
106: End update_dml;
107: --
108: -- ----------------------------------------------------------------------------
137: --
138: -- {End Of Comments}
139: -- ----------------------------------------------------------------------------
140: Procedure pre_update
141: (p_rec in pay_peu_shd.g_rec_type
142: ) is
143: --
144: l_proc varchar2(72) := g_package||'pre_update';
145: --
182: -- {End Of Comments}
183: -- ----------------------------------------------------------------------------
184: Procedure post_update
185: (p_effective_date in date
186: ,p_rec in pay_peu_shd.g_rec_type
187: ) is
188: --
189: l_proc varchar2(72) := g_package||'post_update';
190: --
212: => p_rec.event_type
213: ,p_object_version_number
214: => p_rec.object_version_number
215: ,p_table_name_o
216: => pay_peu_shd.g_old_rec.table_name
217: ,p_column_name_o
218: => pay_peu_shd.g_old_rec.column_name
219: ,p_dated_table_id_o
220: => pay_peu_shd.g_old_rec.dated_table_id
214: => p_rec.object_version_number
215: ,p_table_name_o
216: => pay_peu_shd.g_old_rec.table_name
217: ,p_column_name_o
218: => pay_peu_shd.g_old_rec.column_name
219: ,p_dated_table_id_o
220: => pay_peu_shd.g_old_rec.dated_table_id
221: ,p_business_group_id_o
222: => pay_peu_shd.g_old_rec.business_group_id
216: => pay_peu_shd.g_old_rec.table_name
217: ,p_column_name_o
218: => pay_peu_shd.g_old_rec.column_name
219: ,p_dated_table_id_o
220: => pay_peu_shd.g_old_rec.dated_table_id
221: ,p_business_group_id_o
222: => pay_peu_shd.g_old_rec.business_group_id
223: ,p_legislation_code_o
224: => pay_peu_shd.g_old_rec.legislation_code
218: => pay_peu_shd.g_old_rec.column_name
219: ,p_dated_table_id_o
220: => pay_peu_shd.g_old_rec.dated_table_id
221: ,p_business_group_id_o
222: => pay_peu_shd.g_old_rec.business_group_id
223: ,p_legislation_code_o
224: => pay_peu_shd.g_old_rec.legislation_code
225: ,p_change_type_o
226: => pay_peu_shd.g_old_rec.change_type
220: => pay_peu_shd.g_old_rec.dated_table_id
221: ,p_business_group_id_o
222: => pay_peu_shd.g_old_rec.business_group_id
223: ,p_legislation_code_o
224: => pay_peu_shd.g_old_rec.legislation_code
225: ,p_change_type_o
226: => pay_peu_shd.g_old_rec.change_type
227: ,p_event_type_o
228: => pay_peu_shd.g_old_rec.event_type
222: => pay_peu_shd.g_old_rec.business_group_id
223: ,p_legislation_code_o
224: => pay_peu_shd.g_old_rec.legislation_code
225: ,p_change_type_o
226: => pay_peu_shd.g_old_rec.change_type
227: ,p_event_type_o
228: => pay_peu_shd.g_old_rec.event_type
229: ,p_object_version_number_o
230: => pay_peu_shd.g_old_rec.object_version_number
224: => pay_peu_shd.g_old_rec.legislation_code
225: ,p_change_type_o
226: => pay_peu_shd.g_old_rec.change_type
227: ,p_event_type_o
228: => pay_peu_shd.g_old_rec.event_type
229: ,p_object_version_number_o
230: => pay_peu_shd.g_old_rec.object_version_number
231: );
232: --
226: => pay_peu_shd.g_old_rec.change_type
227: ,p_event_type_o
228: => pay_peu_shd.g_old_rec.event_type
229: ,p_object_version_number_o
230: => pay_peu_shd.g_old_rec.object_version_number
231: );
232: --
233: exception
234: --
286: --
287: -- {End Of Comments}
288: -- ----------------------------------------------------------------------------
289: Procedure convert_defs
290: (p_rec in out nocopy pay_peu_shd.g_rec_type
291: ) is
292: --
293: Begin
294: --
298: -- is being used then we must set to the 'current' argument value.
299: --
300: If (p_rec.table_name = hr_api.g_varchar2) then
301: p_rec.table_name :=
302: pay_peu_shd.g_old_rec.table_name;
303: End If;
304: If (p_rec.column_name = hr_api.g_varchar2) then
305: p_rec.column_name :=
306: pay_peu_shd.g_old_rec.column_name;
302: pay_peu_shd.g_old_rec.table_name;
303: End If;
304: If (p_rec.column_name = hr_api.g_varchar2) then
305: p_rec.column_name :=
306: pay_peu_shd.g_old_rec.column_name;
307: End If;
308: If (p_rec.dated_table_id = hr_api.g_number) then
309: p_rec.dated_table_id :=
310: pay_peu_shd.g_old_rec.dated_table_id;
306: pay_peu_shd.g_old_rec.column_name;
307: End If;
308: If (p_rec.dated_table_id = hr_api.g_number) then
309: p_rec.dated_table_id :=
310: pay_peu_shd.g_old_rec.dated_table_id;
311: End If;
312: If (p_rec.business_group_id = hr_api.g_number) then
313: p_rec.business_group_id :=
314: pay_peu_shd.g_old_rec.business_group_id;
310: pay_peu_shd.g_old_rec.dated_table_id;
311: End If;
312: If (p_rec.business_group_id = hr_api.g_number) then
313: p_rec.business_group_id :=
314: pay_peu_shd.g_old_rec.business_group_id;
315: End If;
316: If (p_rec.legislation_code = hr_api.g_varchar2) then
317: p_rec.legislation_code :=
318: pay_peu_shd.g_old_rec.legislation_code;
314: pay_peu_shd.g_old_rec.business_group_id;
315: End If;
316: If (p_rec.legislation_code = hr_api.g_varchar2) then
317: p_rec.legislation_code :=
318: pay_peu_shd.g_old_rec.legislation_code;
319: End If;
320: If (p_rec.change_type = hr_api.g_varchar2) then
321: p_rec.change_type :=
322: pay_peu_shd.g_old_rec.change_type;
318: pay_peu_shd.g_old_rec.legislation_code;
319: End If;
320: If (p_rec.change_type = hr_api.g_varchar2) then
321: p_rec.change_type :=
322: pay_peu_shd.g_old_rec.change_type;
323: End If;
324: If (p_rec.event_type = hr_api.g_varchar2) then
325: p_rec.event_type :=
326: pay_peu_shd.g_old_rec.event_type;
322: pay_peu_shd.g_old_rec.change_type;
323: End If;
324: If (p_rec.event_type = hr_api.g_varchar2) then
325: p_rec.event_type :=
326: pay_peu_shd.g_old_rec.event_type;
327: End If;
328: --
329: End convert_defs;
330: --
332: -- |---------------------------------< upd >----------------------------------|
333: -- ----------------------------------------------------------------------------
334: Procedure upd
335: (p_effective_date in date
336: ,p_rec in out nocopy pay_peu_shd.g_rec_type
337: ) is
338: --
339: l_proc varchar2(72) := g_package||'upd';
340: --
342: hr_utility.set_location('Entering:'||l_proc, 5);
343: --
344: -- We must lock the row which we need to update.
345: --
346: pay_peu_shd.lck
347: (p_rec.event_update_id
348: ,p_rec.object_version_number
349: );
350: --
391: ,p_legislation_code in varchar2 default hr_api.g_varchar2
392: ,p_event_type in varchar2 default hr_api.g_varchar2
393: ) is
394: --
395: l_rec pay_peu_shd.g_rec_type;
396: l_proc varchar2(72) := g_package||'upd';
397: --
398: Begin
399: hr_utility.set_location('Entering:'||l_proc, 5);
401: -- Call conversion function to turn arguments into the
402: -- l_rec structure.
403: --
404: l_rec :=
405: pay_peu_shd.convert_args
406: (p_event_update_id
407: ,p_table_name
408: ,p_column_name
409: ,p_dated_table_id