83: p_rec.object_version_number := 1; -- Initialise the object version
84: --
85: --
86: --
87: -- Insert the row into: per_objectives_library
88: --
89: insert into per_objectives_library
90: (objective_id
91: ,object_version_number
85: --
86: --
87: -- Insert the row into: per_objectives_library
88: --
89: insert into per_objectives_library
90: (objective_id
91: ,object_version_number
92: ,objective_name
93: ,valid_from
259: Procedure pre_insert
260: (p_rec in out nocopy per_pml_shd.g_rec_type
261: ) is
262: --
263: Cursor C_Sel1 is select per_objectives_library_s.nextval from sys.dual;
264: --
265: Cursor C_Sel2 is
266: Select null
267: from per_objectives_library
263: Cursor C_Sel1 is select per_objectives_library_s.nextval from sys.dual;
264: --
265: Cursor C_Sel2 is
266: Select null
267: from per_objectives_library
268: where objective_id =
269: per_pml_ins.g_objective_id_i;
270: --
271: l_proc varchar2(72) := g_package||'pre_insert';
285: --
286: -- The primary key values are already in use.
287: --
288: fnd_message.set_name('PER','PER_289391_KEY_ALREADY_USED');
289: fnd_message.set_token('TABLE_NAME','per_objectives_library');
290: fnd_message.raise_error;
291: End If;
292: Close C_Sel2;
293: --
475: --
476: when hr_api.cannot_find_prog_unit then
477: --
478: hr_api.cannot_find_prog_unit_error
479: (p_module_name => 'PER_OBJECTIVES_LIBRARY'
480: ,p_hook_type => 'AI');
481: --
482: end;
483: --