[Home] [Help]
222:
223: CLOSE chk_autoalloc_set;
224:
225: -- Delete all of the associated formulas
226: gl_alloc_formulas_pkg.delete_rows(
227: allocation_batch_id);
228:
229: DELETE FROM GL_ALLOC_BATCHES
230: WHERE rowid = X_Rowid;
241:
242:
243: BEGIN
244:
245: INSERT INTO GL_ALLOC_FORMULAS(
246: allocation_formula_id,
247: allocation_batch_id,
248: name,
249: run_sequence,
259: last_update_login,
260: description
261: ) (
262: Select
263: gl_alloc_formulas_s.nextval,
264: X_Trg_Batch_Id,
265: f.Name,
266: f.Run_Sequence,
267: f.Je_Category_Name,
274: sysdate,
275: X_Last_Updated_By,
276: X_Last_Update_Login,
277: f.Description
278: from GL_ALLOC_FORMULAS F
279: where f.Allocation_batch_id = X_Src_Batch_ID
280: );
281:
282:
390: L.Segment27,
391: L.Segment28,
392: L.Segment29,
393: L.Segment30
394: from GL_ALLOC_FORMULA_LINES L, GL_ALLOC_FORMULAS New, GL_ALLOC_FORMULAS Old
395: where L.allocation_formula_id = Old.Allocation_formula_id
396: AND New.allocation_batch_id = X_Trg_Batch_Id
397: AND New.name = Old.name
398: AND Old.allocation_batch_id = X_Src_Batch_Id