66: return l_bill_date;
67:
68: exception
69: when others then
70: fnd_file.put_line(fnd_file.log,' **** Error deriving NEXT BILL DATE: '||SQLERRM||'. ****');
71: return null;
72: end get_next_bill_date;
73:
74: procedure track_next_bill_date ( p_khr_id IN NUMBER )
93:
94: begin
95:
96: if p_khr_id is null then
97: fnd_file.put_line(fnd_file.log,' **** KHR_ID must be supplied for TRACK_NEXT_BILL_DATE. ****');
98: return;
99: end if;
100:
101: l_khr_id := null;
212: l_print_cons_cnt := 0;
213: l_print_xfer_cnt := 0;
214:
215:
216: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
217: fnd_file.put_line(fnd_file.log,'p_source: '||p_source);
218: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
219:
220: IF p_source = 'STREAM_BILLING' THEN
213: l_print_xfer_cnt := 0;
214:
215:
216: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
217: fnd_file.put_line(fnd_file.log,'p_source: '||p_source);
218: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
219:
220: IF p_source = 'STREAM_BILLING' THEN
221:
214:
215:
216: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
217: fnd_file.put_line(fnd_file.log,'p_source: '||p_source);
218: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
219:
220: IF p_source = 'STREAM_BILLING' THEN
221:
222: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
218: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
219:
220: IF p_source = 'STREAM_BILLING' THEN
221:
222: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
223: fnd_file.put_line(fnd_file.log,'** START: Delete all Stream Billing records from OKL_PARALLEL_PROCESSES. **');
224:
225: l_strm_bill_cnt := 0;
226: OPEN cnt_csr ('Master Program -- Process Billable Streams',
219:
220: IF p_source = 'STREAM_BILLING' THEN
221:
222: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
223: fnd_file.put_line(fnd_file.log,'** START: Delete all Stream Billing records from OKL_PARALLEL_PROCESSES. **');
224:
225: l_strm_bill_cnt := 0;
226: OPEN cnt_csr ('Master Program -- Process Billable Streams',
227: 'Process Billable Streams');
229: CLOSE cnt_csr;
230:
231: IF l_strm_bill_cnt > 0 THEN
232:
233: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
234: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Stream Billing '
235: ||'records because not all requests have Completed.');
236: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
237:
230:
231: IF l_strm_bill_cnt > 0 THEN
232:
233: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
234: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Stream Billing '
235: ||'records because not all requests have Completed.');
236: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
237:
238: ELSE
232:
233: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
234: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Stream Billing '
235: ||'records because not all requests have Completed.');
236: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
237:
238: ELSE
239: delete from okl_parallel_processes
240: where OBJECT_TYPE = 'CONTRACT';
240: where OBJECT_TYPE = 'CONTRACT';
241:
242: l_print_strm_cnt := l_print_strm_cnt + (sql%rowcount);
243:
244: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
245: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
246: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
247:
248: commit;
241:
242: l_print_strm_cnt := l_print_strm_cnt + (sql%rowcount);
243:
244: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
245: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
246: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
247:
248: commit;
249: END IF;
242: l_print_strm_cnt := l_print_strm_cnt + (sql%rowcount);
243:
244: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
245: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
246: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
247:
248: commit;
249: END IF;
250: fnd_file.put_line(fnd_file.log,'** END: Delete all Stream Billing records from OKL_PARALLEL_PROCESSES. **');
246: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
247:
248: commit;
249: END IF;
250: fnd_file.put_line(fnd_file.log,'** END: Delete all Stream Billing records from OKL_PARALLEL_PROCESSES. **');
251:
252: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
253: fnd_file.put_line(fnd_file.log,'** START: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
254:
248: commit;
249: END IF;
250: fnd_file.put_line(fnd_file.log,'** END: Delete all Stream Billing records from OKL_PARALLEL_PROCESSES. **');
251:
252: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
253: fnd_file.put_line(fnd_file.log,'** START: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
254:
255: delete from okl_parallel_processes
256: where OBJECT_TYPE = 'CONTRACT'
249: END IF;
250: fnd_file.put_line(fnd_file.log,'** END: Delete all Stream Billing records from OKL_PARALLEL_PROCESSES. **');
251:
252: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
253: fnd_file.put_line(fnd_file.log,'** START: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
254:
255: delete from okl_parallel_processes
256: where OBJECT_TYPE = 'CONTRACT'
257: and org_id = l_org_id
265: and req.PHASE_CODE = 'C');
266:
267: l_print_strm_cnt := l_print_strm_cnt + (sql%rowcount);
268:
269: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
270: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
271: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
272: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
273:
266:
267: l_print_strm_cnt := l_print_strm_cnt + (sql%rowcount);
268:
269: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
270: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
271: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
272: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
273:
274: commit;
267: l_print_strm_cnt := l_print_strm_cnt + (sql%rowcount);
268:
269: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
270: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
271: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
272: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
273:
274: commit;
275: -- rmunjulu R12 fixes -- comment out consolidation
268:
269: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
270: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
271: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
272: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
273:
274: commit;
275: -- rmunjulu R12 fixes -- comment out consolidation
276: /*
275: -- rmunjulu R12 fixes -- comment out consolidation
276: /*
277: ELSIF p_source = 'CONSOLIDATION' THEN
278:
279: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
280: fnd_file.put_line(fnd_file.log,'** START: Delete all Consolidation records from OKL_PARALLEL_PROCESSES. **');
281: l_cnsld_cnt := 0;
282: OPEN cnt_csr ('Master Program -- Receivables Bills Consolidation',
283: 'Receivables Bills Consolidation');
276: /*
277: ELSIF p_source = 'CONSOLIDATION' THEN
278:
279: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
280: fnd_file.put_line(fnd_file.log,'** START: Delete all Consolidation records from OKL_PARALLEL_PROCESSES. **');
281: l_cnsld_cnt := 0;
282: OPEN cnt_csr ('Master Program -- Receivables Bills Consolidation',
283: 'Receivables Bills Consolidation');
284: FETCH cnt_csr INTO l_cnsld_cnt;
284: FETCH cnt_csr INTO l_cnsld_cnt;
285: CLOSE cnt_csr;
286:
287: IF l_cnsld_cnt > 0 THEN
288: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
289: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Consolidation '
290: ||'records because not all requests have Completed.');
291: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
292: ELSE
285: CLOSE cnt_csr;
286:
287: IF l_cnsld_cnt > 0 THEN
288: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
289: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Consolidation '
290: ||'records because not all requests have Completed.');
291: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
292: ELSE
293: delete from okl_parallel_processes
287: IF l_cnsld_cnt > 0 THEN
288: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
289: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Consolidation '
290: ||'records because not all requests have Completed.');
291: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
292: ELSE
293: delete from okl_parallel_processes
294: where OBJECT_TYPE = 'CUSTOMER';
295:
294: where OBJECT_TYPE = 'CUSTOMER';
295:
296: l_print_cons_cnt := l_print_cons_cnt + (sql%rowcount);
297:
298: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
299: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
300: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
301:
302: commit;
295:
296: l_print_cons_cnt := l_print_cons_cnt + (sql%rowcount);
297:
298: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
299: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
300: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
301:
302: commit;
303: END IF;
296: l_print_cons_cnt := l_print_cons_cnt + (sql%rowcount);
297:
298: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
299: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
300: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
301:
302: commit;
303: END IF;
304: fnd_file.put_line(fnd_file.log,'** END: Delete all Consolidation records from OKL_PARALLEL_PROCESSES. **');
300: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
301:
302: commit;
303: END IF;
304: fnd_file.put_line(fnd_file.log,'** END: Delete all Consolidation records from OKL_PARALLEL_PROCESSES. **');
305:
306: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
307: fnd_file.put_line(fnd_file.log,'** START: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
308: delete from okl_parallel_processes
302: commit;
303: END IF;
304: fnd_file.put_line(fnd_file.log,'** END: Delete all Consolidation records from OKL_PARALLEL_PROCESSES. **');
305:
306: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
307: fnd_file.put_line(fnd_file.log,'** START: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
308: delete from okl_parallel_processes
309: where OBJECT_TYPE = 'CUSTOMER'
310: and org_id = l_org_id
303: END IF;
304: fnd_file.put_line(fnd_file.log,'** END: Delete all Consolidation records from OKL_PARALLEL_PROCESSES. **');
305:
306: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
307: fnd_file.put_line(fnd_file.log,'** START: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
308: delete from okl_parallel_processes
309: where OBJECT_TYPE = 'CUSTOMER'
310: and org_id = l_org_id
311: and request_id in (
318: and req.PHASE_CODE = 'C');
319:
320: l_print_cons_cnt := l_print_cons_cnt + (sql%rowcount);
321:
322: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
323: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
324: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
325:
326: commit;
319:
320: l_print_cons_cnt := l_print_cons_cnt + (sql%rowcount);
321:
322: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
323: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
324: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
325:
326: commit;
327: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
320: l_print_cons_cnt := l_print_cons_cnt + (sql%rowcount);
321:
322: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
323: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
324: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
325:
326: commit;
327: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
328: */
323: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
324: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
325:
326: commit;
327: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
328: */
329: ELSIF p_source = 'AR_TRANSFER' THEN
330: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
331: fnd_file.put_line(fnd_file.log,'** START: Delete all Transfer records from OKL_PARALLEL_PROCESSES. **');
326: commit;
327: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
328: */
329: ELSIF p_source = 'AR_TRANSFER' THEN
330: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
331: fnd_file.put_line(fnd_file.log,'** START: Delete all Transfer records from OKL_PARALLEL_PROCESSES. **');
332: l_xfer_cnt := 0;
333: OPEN cnt_csr ('Master Program -- Receivables Invoice Transfer',
334: 'Receivables Invoice Transfer to AR');
327: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
328: */
329: ELSIF p_source = 'AR_TRANSFER' THEN
330: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
331: fnd_file.put_line(fnd_file.log,'** START: Delete all Transfer records from OKL_PARALLEL_PROCESSES. **');
332: l_xfer_cnt := 0;
333: OPEN cnt_csr ('Master Program -- Receivables Invoice Transfer',
334: 'Receivables Invoice Transfer to AR');
335: FETCH cnt_csr INTO l_xfer_cnt;
335: FETCH cnt_csr INTO l_xfer_cnt;
336: CLOSE cnt_csr;
337:
338: IF l_xfer_cnt > 0 THEN
339: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
340: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Transfer '
341: ||'records because not all requests have Completed.');
342: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
343: ELSE
336: CLOSE cnt_csr;
337:
338: IF l_xfer_cnt > 0 THEN
339: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
340: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Transfer '
341: ||'records because not all requests have Completed.');
342: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
343: ELSE
344: delete from okl_parallel_processes
338: IF l_xfer_cnt > 0 THEN
339: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
340: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Transfer '
341: ||'records because not all requests have Completed.');
342: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
343: ELSE
344: delete from okl_parallel_processes
345: where OBJECT_TYPE = 'XTRX_CONTRACT';
346:
345: where OBJECT_TYPE = 'XTRX_CONTRACT';
346:
347: l_print_xfer_cnt := l_print_xfer_cnt + (sql%rowcount);
348:
349: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
350: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
351: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
352:
353: commit;
346:
347: l_print_xfer_cnt := l_print_xfer_cnt + (sql%rowcount);
348:
349: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
350: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
351: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
352:
353: commit;
354: END IF;
347: l_print_xfer_cnt := l_print_xfer_cnt + (sql%rowcount);
348:
349: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
350: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
351: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
352:
353: commit;
354: END IF;
355: fnd_file.put_line(fnd_file.log,'** END: Delete all Transfer records from OKL_PARALLEL_PROCESSES. **');
351: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
352:
353: commit;
354: END IF;
355: fnd_file.put_line(fnd_file.log,'** END: Delete all Transfer records from OKL_PARALLEL_PROCESSES. **');
356:
357: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
358: fnd_file.put_line(fnd_file.log,'** START: Delete Org Specific Transfer records from OKL_PARALLEL_PROCESSES. **');
359: delete from okl_parallel_processes
353: commit;
354: END IF;
355: fnd_file.put_line(fnd_file.log,'** END: Delete all Transfer records from OKL_PARALLEL_PROCESSES. **');
356:
357: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
358: fnd_file.put_line(fnd_file.log,'** START: Delete Org Specific Transfer records from OKL_PARALLEL_PROCESSES. **');
359: delete from okl_parallel_processes
360: where OBJECT_TYPE = 'XTRX_CONTRACT'
361: and org_id = l_org_id
354: END IF;
355: fnd_file.put_line(fnd_file.log,'** END: Delete all Transfer records from OKL_PARALLEL_PROCESSES. **');
356:
357: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
358: fnd_file.put_line(fnd_file.log,'** START: Delete Org Specific Transfer records from OKL_PARALLEL_PROCESSES. **');
359: delete from okl_parallel_processes
360: where OBJECT_TYPE = 'XTRX_CONTRACT'
361: and org_id = l_org_id
362: and request_id in (
369: and req.PHASE_CODE = 'C');
370:
371: l_print_xfer_cnt := l_print_xfer_cnt + (sql%rowcount);
372:
373: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
374: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
375: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
376:
377: commit;
370:
371: l_print_xfer_cnt := l_print_xfer_cnt + (sql%rowcount);
372:
373: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
374: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
375: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
376:
377: commit;
378: fnd_file.put_line(fnd_file.log,'** END: Delete Org Specific Transfer records from OKL_PARALLEL_PROCESSES. **');
371: l_print_xfer_cnt := l_print_xfer_cnt + (sql%rowcount);
372:
373: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
374: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
375: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
376:
377: commit;
378: fnd_file.put_line(fnd_file.log,'** END: Delete Org Specific Transfer records from OKL_PARALLEL_PROCESSES. **');
379: --fmiao 5209209 change
374: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
375: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
376:
377: commit;
378: fnd_file.put_line(fnd_file.log,'** END: Delete Org Specific Transfer records from OKL_PARALLEL_PROCESSES. **');
379: --fmiao 5209209 change
380: -- rmunjulu R12 fixes -- comment out prepare recvbles
381: /*
382: ELSIF p_source = 'AR_PREPARE' THEN
379: --fmiao 5209209 change
380: -- rmunjulu R12 fixes -- comment out prepare recvbles
381: /*
382: ELSIF p_source = 'AR_PREPARE' THEN
383: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
384: Fnd_File.put_line(Fnd_File.LOG,'** START: Delete all Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
385: l_prep_cnt := 0;
386: OPEN cnt_csr ('Master Program -- Prepare Receivables',
387: 'Prepare Receivables Bills');
380: -- rmunjulu R12 fixes -- comment out prepare recvbles
381: /*
382: ELSIF p_source = 'AR_PREPARE' THEN
383: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
384: Fnd_File.put_line(Fnd_File.LOG,'** START: Delete all Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
385: l_prep_cnt := 0;
386: OPEN cnt_csr ('Master Program -- Prepare Receivables',
387: 'Prepare Receivables Bills');
388: FETCH cnt_csr INTO l_prep_cnt;
388: FETCH cnt_csr INTO l_prep_cnt;
389: CLOSE cnt_csr;
390:
391: IF l_prep_cnt > 0 THEN
392: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
393: Fnd_File.put_line(Fnd_File.LOG,' => Could not perform a delete all for Prepare Receivables '
394: ||'records because not all requests have Completed.');
395: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
396: ELSE
389: CLOSE cnt_csr;
390:
391: IF l_prep_cnt > 0 THEN
392: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
393: Fnd_File.put_line(Fnd_File.LOG,' => Could not perform a delete all for Prepare Receivables '
394: ||'records because not all requests have Completed.');
395: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
396: ELSE
397: DELETE FROM okl_parallel_processes
391: IF l_prep_cnt > 0 THEN
392: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
393: Fnd_File.put_line(Fnd_File.LOG,' => Could not perform a delete all for Prepare Receivables '
394: ||'records because not all requests have Completed.');
395: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
396: ELSE
397: DELETE FROM okl_parallel_processes
398: WHERE OBJECT_TYPE = 'PREP_CONTRACT';
399:
398: WHERE OBJECT_TYPE = 'PREP_CONTRACT';
399:
400: l_print_prep_cnt := l_print_prep_cnt + (SQL%rowcount);
401:
402: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
403: Fnd_File.put_line(Fnd_File.LOG,' => Deleted '||SQL%rowcount||' row(s).');
404: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
405:
406: COMMIT;
399:
400: l_print_prep_cnt := l_print_prep_cnt + (SQL%rowcount);
401:
402: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
403: Fnd_File.put_line(Fnd_File.LOG,' => Deleted '||SQL%rowcount||' row(s).');
404: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
405:
406: COMMIT;
407: END IF;
400: l_print_prep_cnt := l_print_prep_cnt + (SQL%rowcount);
401:
402: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
403: Fnd_File.put_line(Fnd_File.LOG,' => Deleted '||SQL%rowcount||' row(s).');
404: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
405:
406: COMMIT;
407: END IF;
408: Fnd_File.put_line(Fnd_File.LOG,'** END: Delete all Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
404: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
405:
406: COMMIT;
407: END IF;
408: Fnd_File.put_line(Fnd_File.LOG,'** END: Delete all Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
409:
410: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
411: Fnd_File.put_line(Fnd_File.LOG,'** START: Delete Org Specific Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
412: DELETE FROM okl_parallel_processes
406: COMMIT;
407: END IF;
408: Fnd_File.put_line(Fnd_File.LOG,'** END: Delete all Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
409:
410: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
411: Fnd_File.put_line(Fnd_File.LOG,'** START: Delete Org Specific Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
412: DELETE FROM okl_parallel_processes
413: WHERE OBJECT_TYPE = 'PREP_CONTRACT'
414: AND org_id = l_org_id
407: END IF;
408: Fnd_File.put_line(Fnd_File.LOG,'** END: Delete all Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
409:
410: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
411: Fnd_File.put_line(Fnd_File.LOG,'** START: Delete Org Specific Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
412: DELETE FROM okl_parallel_processes
413: WHERE OBJECT_TYPE = 'PREP_CONTRACT'
414: AND org_id = l_org_id
415: AND request_id IN (
422: AND req.PHASE_CODE = 'C');
423:
424: l_print_prep_cnt := l_print_prep_cnt + (SQL%rowcount);
425:
426: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
427: Fnd_File.put_line(Fnd_File.LOG,' => Deleted '||SQL%rowcount||' row(s).');
428: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
429:
430: COMMIT;
423:
424: l_print_prep_cnt := l_print_prep_cnt + (SQL%rowcount);
425:
426: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
427: Fnd_File.put_line(Fnd_File.LOG,' => Deleted '||SQL%rowcount||' row(s).');
428: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
429:
430: COMMIT;
431: Fnd_File.put_line(Fnd_File.LOG,'** END: Delete Org Specific Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
424: l_print_prep_cnt := l_print_prep_cnt + (SQL%rowcount);
425:
426: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
427: Fnd_File.put_line(Fnd_File.LOG,' => Deleted '||SQL%rowcount||' row(s).');
428: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
429:
430: COMMIT;
431: Fnd_File.put_line(Fnd_File.LOG,'** END: Delete Org Specific Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
432:
427: Fnd_File.put_line(Fnd_File.LOG,' => Deleted '||SQL%rowcount||' row(s).');
428: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
429:
430: COMMIT;
431: Fnd_File.put_line(Fnd_File.LOG,'** END: Delete Org Specific Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
432:
433: --fmiao 5209209 end
434: */
435: ELSIF p_source = 'ALL' THEN
433: --fmiao 5209209 end
434: */
435: ELSIF p_source = 'ALL' THEN
436:
437: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
438: fnd_file.put_line(fnd_file.log,'** START: Delete all Stream Billing records from OKL_PARALLEL_PROCESSES. **');
439: l_strm_bill_cnt := 0;
440: OPEN cnt_csr ('Master Program -- Process Billable Streams',
441: 'Process Billable Streams');
434: */
435: ELSIF p_source = 'ALL' THEN
436:
437: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
438: fnd_file.put_line(fnd_file.log,'** START: Delete all Stream Billing records from OKL_PARALLEL_PROCESSES. **');
439: l_strm_bill_cnt := 0;
440: OPEN cnt_csr ('Master Program -- Process Billable Streams',
441: 'Process Billable Streams');
442: FETCH cnt_csr INTO l_strm_bill_cnt;
443: CLOSE cnt_csr;
444:
445: IF l_strm_bill_cnt > 0 THEN
446:
447: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
448: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Stream Billing '
449: ||'records because not all requests have Completed.');
450: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
451:
444:
445: IF l_strm_bill_cnt > 0 THEN
446:
447: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
448: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Stream Billing '
449: ||'records because not all requests have Completed.');
450: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
451:
452: ELSE
446:
447: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
448: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Stream Billing '
449: ||'records because not all requests have Completed.');
450: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
451:
452: ELSE
453: delete from okl_parallel_processes
454: where OBJECT_TYPE = 'CONTRACT';
454: where OBJECT_TYPE = 'CONTRACT';
455:
456: l_print_strm_cnt := l_print_strm_cnt + (sql%rowcount);
457:
458: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
459: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
460: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
461:
462: commit;
455:
456: l_print_strm_cnt := l_print_strm_cnt + (sql%rowcount);
457:
458: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
459: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
460: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
461:
462: commit;
463: END IF;
456: l_print_strm_cnt := l_print_strm_cnt + (sql%rowcount);
457:
458: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
459: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
460: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
461:
462: commit;
463: END IF;
464: fnd_file.put_line(fnd_file.log,'** END: Delete all Stream Billing records from OKL_PARALLEL_PROCESSES. **');
460: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
461:
462: commit;
463: END IF;
464: fnd_file.put_line(fnd_file.log,'** END: Delete all Stream Billing records from OKL_PARALLEL_PROCESSES. **');
465:
466: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
467: fnd_file.put_line(fnd_file.log,'** START: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
468:
462: commit;
463: END IF;
464: fnd_file.put_line(fnd_file.log,'** END: Delete all Stream Billing records from OKL_PARALLEL_PROCESSES. **');
465:
466: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
467: fnd_file.put_line(fnd_file.log,'** START: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
468:
469: delete from okl_parallel_processes
470: where OBJECT_TYPE = 'CONTRACT'
463: END IF;
464: fnd_file.put_line(fnd_file.log,'** END: Delete all Stream Billing records from OKL_PARALLEL_PROCESSES. **');
465:
466: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
467: fnd_file.put_line(fnd_file.log,'** START: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
468:
469: delete from okl_parallel_processes
470: where OBJECT_TYPE = 'CONTRACT'
471: and org_id = l_org_id
479: and req.PHASE_CODE = 'C');
480:
481: l_print_strm_cnt := l_print_strm_cnt + (sql%rowcount);
482:
483: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
484: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
485: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
486: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
487:
480:
481: l_print_strm_cnt := l_print_strm_cnt + (sql%rowcount);
482:
483: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
484: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
485: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
486: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
487:
488: commit;
481: l_print_strm_cnt := l_print_strm_cnt + (sql%rowcount);
482:
483: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
484: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
485: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
486: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
487:
488: commit;
489:
482:
483: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
484: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
485: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
486: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Stream Billing records from OKL_PARALLEL_PROCESSES. **');
487:
488: commit;
489:
490: -- rmunjulu R12 fixes -- comment out consolidation
488: commit;
489:
490: -- rmunjulu R12 fixes -- comment out consolidation
491: /*
492: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
493: fnd_file.put_line(fnd_file.log,'** START: Delete all Consolidation records from OKL_PARALLEL_PROCESSES. **');
494: l_cnsld_cnt := 0;
495: OPEN cnt_csr ('Master Program -- Receivables Bills Consolidation',
496: 'Receivables Bills Consolidation');
489:
490: -- rmunjulu R12 fixes -- comment out consolidation
491: /*
492: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
493: fnd_file.put_line(fnd_file.log,'** START: Delete all Consolidation records from OKL_PARALLEL_PROCESSES. **');
494: l_cnsld_cnt := 0;
495: OPEN cnt_csr ('Master Program -- Receivables Bills Consolidation',
496: 'Receivables Bills Consolidation');
497: FETCH cnt_csr INTO l_cnsld_cnt;
497: FETCH cnt_csr INTO l_cnsld_cnt;
498: CLOSE cnt_csr;
499:
500: IF l_cnsld_cnt > 0 THEN
501: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
502: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Consolidation '
503: ||'records because not all requests have Completed.');
504: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
505: ELSE
498: CLOSE cnt_csr;
499:
500: IF l_cnsld_cnt > 0 THEN
501: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
502: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Consolidation '
503: ||'records because not all requests have Completed.');
504: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
505: ELSE
506: delete from okl_parallel_processes
500: IF l_cnsld_cnt > 0 THEN
501: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
502: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Consolidation '
503: ||'records because not all requests have Completed.');
504: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
505: ELSE
506: delete from okl_parallel_processes
507: where OBJECT_TYPE = 'CUSTOMER';
508:
507: where OBJECT_TYPE = 'CUSTOMER';
508:
509: l_print_cons_cnt := l_print_cons_cnt + (sql%rowcount);
510:
511: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
512: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
513: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
514: commit;
515: END IF;
508:
509: l_print_cons_cnt := l_print_cons_cnt + (sql%rowcount);
510:
511: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
512: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
513: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
514: commit;
515: END IF;
516: fnd_file.put_line(fnd_file.log,'** END: Delete all Consolidation records from OKL_PARALLEL_PROCESSES. **');
509: l_print_cons_cnt := l_print_cons_cnt + (sql%rowcount);
510:
511: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
512: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
513: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
514: commit;
515: END IF;
516: fnd_file.put_line(fnd_file.log,'** END: Delete all Consolidation records from OKL_PARALLEL_PROCESSES. **');
517:
512: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
513: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
514: commit;
515: END IF;
516: fnd_file.put_line(fnd_file.log,'** END: Delete all Consolidation records from OKL_PARALLEL_PROCESSES. **');
517:
518: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
519: fnd_file.put_line(fnd_file.log,'** START: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
520:
514: commit;
515: END IF;
516: fnd_file.put_line(fnd_file.log,'** END: Delete all Consolidation records from OKL_PARALLEL_PROCESSES. **');
517:
518: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
519: fnd_file.put_line(fnd_file.log,'** START: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
520:
521: delete from okl_parallel_processes
522: where OBJECT_TYPE = 'CUSTOMER'
515: END IF;
516: fnd_file.put_line(fnd_file.log,'** END: Delete all Consolidation records from OKL_PARALLEL_PROCESSES. **');
517:
518: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
519: fnd_file.put_line(fnd_file.log,'** START: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
520:
521: delete from okl_parallel_processes
522: where OBJECT_TYPE = 'CUSTOMER'
523: and org_id = l_org_id
531: and req.PHASE_CODE = 'C');
532:
533: l_print_cons_cnt := l_print_cons_cnt + (sql%rowcount);
534:
535: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
536: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
537: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
538:
539: commit;
532:
533: l_print_cons_cnt := l_print_cons_cnt + (sql%rowcount);
534:
535: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
536: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
537: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
538:
539: commit;
540: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
533: l_print_cons_cnt := l_print_cons_cnt + (sql%rowcount);
534:
535: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
536: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
537: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
538:
539: commit;
540: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
541: */
536: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
537: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
538:
539: commit;
540: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
541: */
542: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
543: fnd_file.put_line(fnd_file.log,'** START: Delete all Transfer records from OKL_PARALLEL_PROCESSES. **');
544:
538:
539: commit;
540: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
541: */
542: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
543: fnd_file.put_line(fnd_file.log,'** START: Delete all Transfer records from OKL_PARALLEL_PROCESSES. **');
544:
545: l_xfer_cnt := 0;
546:
539: commit;
540: fnd_file.put_line(fnd_file.log,'** END: Delete Org specific Consolidation records from OKL_PARALLEL_PROCESSES. **');
541: */
542: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
543: fnd_file.put_line(fnd_file.log,'** START: Delete all Transfer records from OKL_PARALLEL_PROCESSES. **');
544:
545: l_xfer_cnt := 0;
546:
547: OPEN cnt_csr ('Master Program -- Receivables Invoice Transfer',
549: FETCH cnt_csr INTO l_xfer_cnt;
550: CLOSE cnt_csr;
551:
552: IF l_xfer_cnt > 0 THEN
553: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
554: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Transfer '
555: ||'records because not all requests have Completed.');
556: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
557: ELSE
550: CLOSE cnt_csr;
551:
552: IF l_xfer_cnt > 0 THEN
553: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
554: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Transfer '
555: ||'records because not all requests have Completed.');
556: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
557: ELSE
558: delete from okl_parallel_processes
552: IF l_xfer_cnt > 0 THEN
553: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
554: fnd_file.put_line(fnd_file.log,' => Could not perform a delete all for Transfer '
555: ||'records because not all requests have Completed.');
556: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
557: ELSE
558: delete from okl_parallel_processes
559: where OBJECT_TYPE = 'XTRX_CONTRACT';
560:
559: where OBJECT_TYPE = 'XTRX_CONTRACT';
560:
561: l_print_xfer_cnt := l_print_xfer_cnt + (sql%rowcount);
562:
563: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
564: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
565: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
566:
567: commit;
560:
561: l_print_xfer_cnt := l_print_xfer_cnt + (sql%rowcount);
562:
563: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
564: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
565: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
566:
567: commit;
568: END IF;
561: l_print_xfer_cnt := l_print_xfer_cnt + (sql%rowcount);
562:
563: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
564: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
565: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
566:
567: commit;
568: END IF;
569:
566:
567: commit;
568: END IF;
569:
570: fnd_file.put_line(fnd_file.log,'** END: Delete all Transfer records from OKL_PARALLEL_PROCESSES. **');
571:
572: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
573: fnd_file.put_line(fnd_file.log,'** START: Delete Org Specific Transfer records from OKL_PARALLEL_PROCESSES. **');
574: delete from okl_parallel_processes
568: END IF;
569:
570: fnd_file.put_line(fnd_file.log,'** END: Delete all Transfer records from OKL_PARALLEL_PROCESSES. **');
571:
572: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
573: fnd_file.put_line(fnd_file.log,'** START: Delete Org Specific Transfer records from OKL_PARALLEL_PROCESSES. **');
574: delete from okl_parallel_processes
575: where OBJECT_TYPE = 'XTRX_CONTRACT'
576: and org_id = l_org_id
569:
570: fnd_file.put_line(fnd_file.log,'** END: Delete all Transfer records from OKL_PARALLEL_PROCESSES. **');
571:
572: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
573: fnd_file.put_line(fnd_file.log,'** START: Delete Org Specific Transfer records from OKL_PARALLEL_PROCESSES. **');
574: delete from okl_parallel_processes
575: where OBJECT_TYPE = 'XTRX_CONTRACT'
576: and org_id = l_org_id
577: and request_id in (
584: and req.PHASE_CODE = 'C');
585:
586: l_print_xfer_cnt := l_print_xfer_cnt + (sql%rowcount);
587:
588: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
589: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
590: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
591:
592: commit;
585:
586: l_print_xfer_cnt := l_print_xfer_cnt + (sql%rowcount);
587:
588: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
589: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
590: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
591:
592: commit;
593:
586: l_print_xfer_cnt := l_print_xfer_cnt + (sql%rowcount);
587:
588: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
589: fnd_file.put_line(fnd_file.log,' => Deleted '||sql%rowcount||' row(s).');
590: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
591:
592: commit;
593:
594: fnd_file.put_line(fnd_file.log,'** END: Delete Org Specific Transfer records from OKL_PARALLEL_PROCESSES. **');
590: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
591:
592: commit;
593:
594: fnd_file.put_line(fnd_file.log,'** END: Delete Org Specific Transfer records from OKL_PARALLEL_PROCESSES. **');
595: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
596:
597: -- rmunjulu R12 fixes -- comment out prepare recvbles
598: /*
591:
592: commit;
593:
594: fnd_file.put_line(fnd_file.log,'** END: Delete Org Specific Transfer records from OKL_PARALLEL_PROCESSES. **');
595: Fnd_File.PUT_LINE (fnd_file.log,RPAD(' ', 132, ' '));
596:
597: -- rmunjulu R12 fixes -- comment out prepare recvbles
598: /*
599: --fmiao 5209209 change
596:
597: -- rmunjulu R12 fixes -- comment out prepare recvbles
598: /*
599: --fmiao 5209209 change
600: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
601: Fnd_File.put_line(Fnd_File.LOG,'** START: Delete all Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
602:
603: l_prep_cnt := 0;
604:
597: -- rmunjulu R12 fixes -- comment out prepare recvbles
598: /*
599: --fmiao 5209209 change
600: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
601: Fnd_File.put_line(Fnd_File.LOG,'** START: Delete all Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
602:
603: l_prep_cnt := 0;
604:
605: OPEN cnt_csr ('Master Program -- Prepare Receivables',
607: FETCH cnt_csr INTO l_prep_cnt;
608: CLOSE cnt_csr;
609:
610: IF l_prep_cnt > 0 THEN
611: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
612: Fnd_File.put_line(Fnd_File.LOG,' => Could not perform a delete all for Prepare Receivables '
613: ||'records because not all requests have Completed.');
614: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
615: ELSE
608: CLOSE cnt_csr;
609:
610: IF l_prep_cnt > 0 THEN
611: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
612: Fnd_File.put_line(Fnd_File.LOG,' => Could not perform a delete all for Prepare Receivables '
613: ||'records because not all requests have Completed.');
614: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
615: ELSE
616: DELETE FROM okl_parallel_processes
610: IF l_prep_cnt > 0 THEN
611: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
612: Fnd_File.put_line(Fnd_File.LOG,' => Could not perform a delete all for Prepare Receivables '
613: ||'records because not all requests have Completed.');
614: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
615: ELSE
616: DELETE FROM okl_parallel_processes
617: WHERE OBJECT_TYPE = 'PREP_CONTRACT';
618:
617: WHERE OBJECT_TYPE = 'PREP_CONTRACT';
618:
619: l_print_prep_cnt := l_print_prep_cnt + (SQL%rowcount);
620:
621: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
622: Fnd_File.put_line(Fnd_File.LOG,' => Deleted '||SQL%rowcount||' row(s).');
623: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
624:
625: COMMIT;
618:
619: l_print_prep_cnt := l_print_prep_cnt + (SQL%rowcount);
620:
621: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
622: Fnd_File.put_line(Fnd_File.LOG,' => Deleted '||SQL%rowcount||' row(s).');
623: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
624:
625: COMMIT;
626: END IF;
619: l_print_prep_cnt := l_print_prep_cnt + (SQL%rowcount);
620:
621: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
622: Fnd_File.put_line(Fnd_File.LOG,' => Deleted '||SQL%rowcount||' row(s).');
623: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
624:
625: COMMIT;
626: END IF;
627:
624:
625: COMMIT;
626: END IF;
627:
628: Fnd_File.put_line(Fnd_File.LOG,'** END: Delete all Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
629:
630: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
631: Fnd_File.put_line(Fnd_File.LOG,'** START: Delete Org Specific Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
632: DELETE FROM okl_parallel_processes
626: END IF;
627:
628: Fnd_File.put_line(Fnd_File.LOG,'** END: Delete all Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
629:
630: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
631: Fnd_File.put_line(Fnd_File.LOG,'** START: Delete Org Specific Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
632: DELETE FROM okl_parallel_processes
633: WHERE OBJECT_TYPE = 'PREP_CONTRACT'
634: AND org_id = l_org_id
627:
628: Fnd_File.put_line(Fnd_File.LOG,'** END: Delete all Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
629:
630: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
631: Fnd_File.put_line(Fnd_File.LOG,'** START: Delete Org Specific Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
632: DELETE FROM okl_parallel_processes
633: WHERE OBJECT_TYPE = 'PREP_CONTRACT'
634: AND org_id = l_org_id
635: AND request_id IN (
642: AND req.PHASE_CODE = 'C');
643:
644: l_print_prep_cnt := l_print_prep_cnt + (SQL%rowcount);
645:
646: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
647: Fnd_File.put_line(Fnd_File.LOG,' => Deleted '||SQL%rowcount||' row(s).');
648: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
649:
650: COMMIT;
643:
644: l_print_prep_cnt := l_print_prep_cnt + (SQL%rowcount);
645:
646: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
647: Fnd_File.put_line(Fnd_File.LOG,' => Deleted '||SQL%rowcount||' row(s).');
648: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
649:
650: COMMIT;
651:
644: l_print_prep_cnt := l_print_prep_cnt + (SQL%rowcount);
645:
646: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
647: Fnd_File.put_line(Fnd_File.LOG,' => Deleted '||SQL%rowcount||' row(s).');
648: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
649:
650: COMMIT;
651:
652: Fnd_File.put_line(Fnd_File.LOG,'** END: Delete Org Specific Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
648: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
649:
650: COMMIT;
651:
652: Fnd_File.put_line(Fnd_File.LOG,'** END: Delete Org Specific Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
653: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
654: --fmiao 5209209 end
655: */
656: END IF;
649:
650: COMMIT;
651:
652: Fnd_File.put_line(Fnd_File.LOG,'** END: Delete Org Specific Prepare Receivables records from OKL_PARALLEL_PROCESSES. **');
653: Fnd_File.PUT_LINE (Fnd_File.LOG,RPAD(' ', 132, ' '));
654: --fmiao 5209209 end
655: */
656: END IF;
657: -- ------------------------
666: FETCH op_unit_csr INTO l_op_unit_name;
667: CLOSE op_unit_csr; */ --commented for Multi Org records
668:
669: -- Start New Out File stmathew 15-OCT-2004
670: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 54, ' ')||'Oracle Leasing and Finance Management'||LPAD(' ', 55, ' '));
671: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
672: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'Purge Parallel Porcesses Table'||LPAD(' ', 51, ' '));
673: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'------------------------------'||LPAD(' ', 51, ' '));
674: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
667: CLOSE op_unit_csr; */ --commented for Multi Org records
668:
669: -- Start New Out File stmathew 15-OCT-2004
670: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 54, ' ')||'Oracle Leasing and Finance Management'||LPAD(' ', 55, ' '));
671: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
672: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'Purge Parallel Porcesses Table'||LPAD(' ', 51, ' '));
673: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'------------------------------'||LPAD(' ', 51, ' '));
674: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
675: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
668:
669: -- Start New Out File stmathew 15-OCT-2004
670: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 54, ' ')||'Oracle Leasing and Finance Management'||LPAD(' ', 55, ' '));
671: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
672: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'Purge Parallel Porcesses Table'||LPAD(' ', 51, ' '));
673: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'------------------------------'||LPAD(' ', 51, ' '));
674: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
675: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
676: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Operating Unit: '||l_op_unit_name);
669: -- Start New Out File stmathew 15-OCT-2004
670: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 54, ' ')||'Oracle Leasing and Finance Management'||LPAD(' ', 55, ' '));
671: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
672: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'Purge Parallel Porcesses Table'||LPAD(' ', 51, ' '));
673: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'------------------------------'||LPAD(' ', 51, ' '));
674: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
675: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
676: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Operating Unit: '||l_op_unit_name);
677: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Request Id: '||l_request_id||LPAD(' ',74,' ') ||'Run Date: '||TO_CHAR(SYSDATE));
670: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 54, ' ')||'Oracle Leasing and Finance Management'||LPAD(' ', 55, ' '));
671: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
672: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'Purge Parallel Porcesses Table'||LPAD(' ', 51, ' '));
673: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'------------------------------'||LPAD(' ', 51, ' '));
674: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
675: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
676: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Operating Unit: '||l_op_unit_name);
677: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Request Id: '||l_request_id||LPAD(' ',74,' ') ||'Run Date: '||TO_CHAR(SYSDATE));
678: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Currency: '||Okl_Accounting_Util.get_func_curr_code);
671: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
672: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'Purge Parallel Porcesses Table'||LPAD(' ', 51, ' '));
673: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'------------------------------'||LPAD(' ', 51, ' '));
674: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
675: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
676: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Operating Unit: '||l_op_unit_name);
677: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Request Id: '||l_request_id||LPAD(' ',74,' ') ||'Run Date: '||TO_CHAR(SYSDATE));
678: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Currency: '||Okl_Accounting_Util.get_func_curr_code);
679: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
672: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'Purge Parallel Porcesses Table'||LPAD(' ', 51, ' '));
673: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'------------------------------'||LPAD(' ', 51, ' '));
674: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
675: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
676: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Operating Unit: '||l_op_unit_name);
677: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Request Id: '||l_request_id||LPAD(' ',74,' ') ||'Run Date: '||TO_CHAR(SYSDATE));
678: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Currency: '||Okl_Accounting_Util.get_func_curr_code);
679: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
680: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, 'Billing Source : ' ||p_source);
673: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 51, ' ')||'------------------------------'||LPAD(' ', 51, ' '));
674: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
675: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
676: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Operating Unit: '||l_op_unit_name);
677: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Request Id: '||l_request_id||LPAD(' ',74,' ') ||'Run Date: '||TO_CHAR(SYSDATE));
678: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Currency: '||Okl_Accounting_Util.get_func_curr_code);
679: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
680: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, 'Billing Source : ' ||p_source);
681: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
674: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
675: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
676: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Operating Unit: '||l_op_unit_name);
677: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Request Id: '||l_request_id||LPAD(' ',74,' ') ||'Run Date: '||TO_CHAR(SYSDATE));
678: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Currency: '||Okl_Accounting_Util.get_func_curr_code);
679: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
680: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, 'Billing Source : ' ||p_source);
681: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
682: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
675: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
676: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Operating Unit: '||l_op_unit_name);
677: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Request Id: '||l_request_id||LPAD(' ',74,' ') ||'Run Date: '||TO_CHAR(SYSDATE));
678: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Currency: '||Okl_Accounting_Util.get_func_curr_code);
679: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
680: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, 'Billing Source : ' ||p_source);
681: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
682: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
683: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
676: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Operating Unit: '||l_op_unit_name);
677: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Request Id: '||l_request_id||LPAD(' ',74,' ') ||'Run Date: '||TO_CHAR(SYSDATE));
678: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Currency: '||Okl_Accounting_Util.get_func_curr_code);
679: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
680: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, 'Billing Source : ' ||p_source);
681: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
682: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
683: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
684:
677: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Request Id: '||l_request_id||LPAD(' ',74,' ') ||'Run Date: '||TO_CHAR(SYSDATE));
678: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Currency: '||Okl_Accounting_Util.get_func_curr_code);
679: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
680: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, 'Billing Source : ' ||p_source);
681: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
682: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
683: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
684:
685: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Processing Details:'||LPAD(' ', 113, ' '));
678: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Currency: '||Okl_Accounting_Util.get_func_curr_code);
679: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
680: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, 'Billing Source : ' ||p_source);
681: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
682: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
683: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
684:
685: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Processing Details:'||LPAD(' ', 113, ' '));
686: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
679: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
680: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, 'Billing Source : ' ||p_source);
681: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
682: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
683: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
684:
685: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Processing Details:'||LPAD(' ', 113, ' '));
686: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
687: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Stream Billing Records: '||l_print_strm_cnt);
681: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD('-', 132, '-'));
682: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
683: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
684:
685: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Processing Details:'||LPAD(' ', 113, ' '));
686: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
687: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Stream Billing Records: '||l_print_strm_cnt);
688: -- rmunjulu R12 Fixes - comment out consolidation
689: -- Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Consolidation Records : '||l_print_cons_cnt);
682: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
683: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
684:
685: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Processing Details:'||LPAD(' ', 113, ' '));
686: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
687: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Stream Billing Records: '||l_print_strm_cnt);
688: -- rmunjulu R12 Fixes - comment out consolidation
689: -- Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Consolidation Records : '||l_print_cons_cnt);
690: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted AR Transfer Records : '||l_print_xfer_cnt);
683: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
684:
685: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Processing Details:'||LPAD(' ', 113, ' '));
686: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
687: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Stream Billing Records: '||l_print_strm_cnt);
688: -- rmunjulu R12 Fixes - comment out consolidation
689: -- Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Consolidation Records : '||l_print_cons_cnt);
690: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted AR Transfer Records : '||l_print_xfer_cnt);
691: --fmiao 5209209 change
685: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,'Processing Details:'||LPAD(' ', 113, ' '));
686: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
687: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Stream Billing Records: '||l_print_strm_cnt);
688: -- rmunjulu R12 Fixes - comment out consolidation
689: -- Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Consolidation Records : '||l_print_cons_cnt);
690: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted AR Transfer Records : '||l_print_xfer_cnt);
691: --fmiao 5209209 change
692: -- rmunjulu R12 fixes -- comment out prepare recvbles
693: -- Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Prepare Recievables Records : '||l_print_prep_cnt);
686: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
687: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Stream Billing Records: '||l_print_strm_cnt);
688: -- rmunjulu R12 Fixes - comment out consolidation
689: -- Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Consolidation Records : '||l_print_cons_cnt);
690: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted AR Transfer Records : '||l_print_xfer_cnt);
691: --fmiao 5209209 change
692: -- rmunjulu R12 fixes -- comment out prepare recvbles
693: -- Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Prepare Recievables Records : '||l_print_prep_cnt);
694: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Total: '||(l_print_strm_cnt+l_print_cons_cnt+l_print_xfer_cnt+l_print_prep_cnt));
689: -- Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Consolidation Records : '||l_print_cons_cnt);
690: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted AR Transfer Records : '||l_print_xfer_cnt);
691: --fmiao 5209209 change
692: -- rmunjulu R12 fixes -- comment out prepare recvbles
693: -- Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Prepare Recievables Records : '||l_print_prep_cnt);
694: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Total: '||(l_print_strm_cnt+l_print_cons_cnt+l_print_xfer_cnt+l_print_prep_cnt));
695: -- fmiao 5209209 end
696: --Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Total: '||(l_print_strm_cnt+l_print_cons_cnt+l_print_xfer_cnt));
697: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
690: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted AR Transfer Records : '||l_print_xfer_cnt);
691: --fmiao 5209209 change
692: -- rmunjulu R12 fixes -- comment out prepare recvbles
693: -- Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Prepare Recievables Records : '||l_print_prep_cnt);
694: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Total: '||(l_print_strm_cnt+l_print_cons_cnt+l_print_xfer_cnt+l_print_prep_cnt));
695: -- fmiao 5209209 end
696: --Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Total: '||(l_print_strm_cnt+l_print_cons_cnt+l_print_xfer_cnt));
697: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
698: End Loop; --for Multi Org records
692: -- rmunjulu R12 fixes -- comment out prepare recvbles
693: -- Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Prepare Recievables Records : '||l_print_prep_cnt);
694: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Total: '||(l_print_strm_cnt+l_print_cons_cnt+l_print_xfer_cnt+l_print_prep_cnt));
695: -- fmiao 5209209 end
696: --Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Total: '||(l_print_strm_cnt+l_print_cons_cnt+l_print_xfer_cnt));
697: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
698: End Loop; --for Multi Org records
699:
700: EXCEPTION
693: -- Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Number of Deleted Prepare Recievables Records : '||l_print_prep_cnt);
694: Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Total: '||(l_print_strm_cnt+l_print_cons_cnt+l_print_xfer_cnt+l_print_prep_cnt));
695: -- fmiao 5209209 end
696: --Fnd_File.PUT_LINE (Fnd_File.OUTPUT, ' Total: '||(l_print_strm_cnt+l_print_cons_cnt+l_print_xfer_cnt));
697: Fnd_File.PUT_LINE (Fnd_File.OUTPUT,RPAD(' ', 132, ' '));
698: End Loop; --for Multi Org records
699:
700: EXCEPTION
701: WHEN OTHERS THEN
698: End Loop; --for Multi Org records
699:
700: EXCEPTION
701: WHEN OTHERS THEN
702: fnd_file.put_line (fnd_file.log,'Purge Program failed with error: '||SQLERRM);
703: END PURGE_PARALLEL_PROCESSES;
704: -- End Bug 4546873;
705:
706: -- -------------------------------------------------
716:
717: end if;
718:
719: if L_DEBUG_ENABLED = 'Y' then
720: fnd_file.put_line (fnd_file.log,p_message);
721: okl_debug_pub.logmessage(p_message);
722: end if;
723:
724: -- dbms_output.put_line(p_message);
728: p_message IN VARCHAR2
729: ) IS
730: BEGIN
731: --dbms_output.put_line(p_message);
732: fnd_file.put_line(fnd_file.output, p_message);
733: END write_to_log;
734:
735:
736: PROCEDURE Process_Spawner (
4248: OPEN c;
4249: LOOP
4250: cons_bill_tbl.delete;
4251: FETCH C BULK COLLECT INTO cons_bill_tbl LIMIT L_FETCH_SIZE;
4252: FND_FILE.PUT_LINE (FND_FILE.LOG, 'C cons_bill_tbl count is: '||cons_bill_tbl.COUNT);
4253: IF cons_bill_tbl.COUNT > 0 THEN
4254: process_cons_bill_tbl(
4255: p_contract_number => p_contract_number,
4256: p_api_version => p_api_version,
4740: LOOP
4741: cons_bill_tbl.delete;
4742: FETCH C1 BULK COLLECT INTO cons_bill_tbl LIMIT L_FETCH_SIZE;
4743:
4744: FND_FILE.PUT_LINE (FND_FILE.LOG, 'C1 cons_bill_tbl count is: '||cons_bill_tbl.COUNT);
4745: IF cons_bill_tbl.COUNT > 0 THEN
4746: process_cons_bill_tbl(
4747: p_contract_number => p_contract_number,
4748: p_api_version => p_api_version,