[Home] [Help]
83: p_rec.object_version_number := 1; -- Initialise the object version
84: --
85: psp_prt_shd.g_api_dml := true; -- Set the api dml status
86: --
87: -- Insert the row into: psp_report_templates
88: --
89: insert into psp_report_templates
90: (template_id
91: ,template_name
85: psp_prt_shd.g_api_dml := true; -- Set the api dml status
86: --
87: -- Insert the row into: psp_report_templates
88: --
89: insert into psp_report_templates
90: (template_id
91: ,template_name
92: ,business_group_id
93: ,set_of_books_id
197: Procedure pre_insert
198: (p_rec in out nocopy psp_prt_shd.g_rec_type
199: ) is
200: --
201: Cursor C_Sel1 is select psp_report_templates_s.nextval from sys.dual;
202: --
203: Cursor C_Sel2 is
204: Select null
205: from psp_report_templates
201: Cursor C_Sel1 is select psp_report_templates_s.nextval from sys.dual;
202: --
203: Cursor C_Sel2 is
204: Select null
205: from psp_report_templates
206: where template_id =
207: psp_prt_ins.g_template_id_i;
208: --
209: l_proc varchar2(72) := g_package||'pre_insert';
223: --
224: -- The primary key values are already in use.
225: --
226: fnd_message.set_name('PER','PER_289391_KEY_ALREADY_USED');
227: fnd_message.set_token('TABLE_NAME','psp_report_templates');
228: fnd_message.raise_error;
229: End If;
230: Close C_Sel2;
231: --
340: --
341: when hr_api.cannot_find_prog_unit then
342: --
343: hr_api.cannot_find_prog_unit_error
344: (p_module_name => 'PSP_REPORT_TEMPLATES'
345: ,p_hook_type => 'AI');
346: --
347: end;
348: --