DBA Data[Home] [Help]

APPS.PO_ENCUMBRANCE_POSTPROCESSING dependencies on PO_BC_DISTRIBUTIONS

Line 280: PROCEDURE delete_po_bc_distributions

276: , x_online_report_id OUT NOCOPY NUMBER
277: );
278:
279: --
280: PROCEDURE delete_po_bc_distributions
281: (
282: p_packet_id IN NUMBER
283: ) ;
284:

Line 308: -- be inserted into PO_BC_DISTRIBUTIONS.

304: --Start of Comments
305: --Name: insert_packet
306: --Pre-reqs:
307: -- PO_ENCUMBRANCE_GT has been updated with the data that should
308: -- be inserted into PO_BC_DISTRIBUTIONS.
309: --Modifies:
310: -- GL_BC_PACKETS
311: --Locks:
312: -- None.

Line 315: -- PO_ENCUMBRANCE_GT into PO_BC_DISTRIBUTIONS. It does this through

311: --Locks:
312: -- None.
313: --Function:
314: -- This procedure inserts all of the entries in
315: -- PO_ENCUMBRANCE_GT into PO_BC_DISTRIBUTIONS. It does this through
316: -- an autonomous transaction helper procedure, as GL needs the data
317: -- committed, but we don't want to commit anything else.
318: --Parameters:
319: --IN:

Line 330: -- The PO_BC_DISTRIBUTIONS.packet_id that was used for this packet.

326: --p_currency_code
327: -- The currency code for the current org.
328: --OUT:
329: --x_packet_id
330: -- The PO_BC_DISTRIBUTIONS.packet_id that was used for this packet.
331: -- If a packet was not created, this will be NULL.
332: --Testing:
333: --
334: --End of Comments

Line 391: FROM po_bc_distributions

387: -- So clearing the event GT table before we insert any new event.
388:
389: DELETE FROM psa_bc_xla_events_gt
390: WHERE event_id IN ( SELECT distinct ae_event_id
391: FROM po_bc_distributions
392: WHERE packet_id <> x_packet_id
393: );
394:
395:

Line 402: FROM po_bc_distributions

398: event_id,
399: result_code -- Bug #4637958
400: )
401: SELECT distinct ae_event_id,'XLA_ERROR'
402: FROM po_bc_distributions
403: WHERE packet_id = x_packet_id;
404: END IF;
405:
406: l_progress := '300';

Line 427: -- PO_BC_DISTRIBUTIONS

423: --Name: INSERT_PACKET_CREATE_EVENT
424: --Pre-reqs:
425: -- None.
426: --Modifies:
427: -- PO_BC_DISTRIBUTIONS
428: --Locks:
429: -- None.
430: --Function:
431: -- This procedure takes its input parameters and inserts and

Line 432: -- transfers data from po_encumbrance_gt to po_bc_distributions.

428: --Locks:
429: -- None.
430: --Function:
431: -- This procedure takes its input parameters and inserts and
432: -- transfers data from po_encumbrance_gt to po_bc_distributions.
433: --Parameters:
434: --IN:
435: -- p_status_code
436: -- Specifies whether this is a Funds Check (C) or a real (pending) action (P).

Line 445: -- The PO_BC_DISTRIBUTIONS.packet_id that was used for this packet.

441: -- p_currency_code
442: -- The currency code for the current org.
443: --OUT:
444: --x_packet_id
445: -- The PO_BC_DISTRIBUTIONS.packet_id that was used for this packet.
446: --Testing:
447: --
448: --End of Comments
449: -------------------------------------------------------------------------------

Line 477: -- SQL What: Querying for records in po_bc_distributions

473: l_event_type_code VARCHAR2(50) ;
474:
475: --
476: CURSOR cur_po_bc_dist_back_recreated IS
477: -- SQL What: Querying for records in po_bc_distributions
478: -- SQL Why : Need to get all the Main Documents ID and Type.
479: SELECT distinct distribution_id,distribution_type
480: FROM po_bc_distributions
481: WHERE packet_id = x_packet_id

Line 480: FROM po_bc_distributions

476: CURSOR cur_po_bc_dist_back_recreated IS
477: -- SQL What: Querying for records in po_bc_distributions
478: -- SQL Why : Need to get all the Main Documents ID and Type.
479: SELECT distinct distribution_id,distribution_type
480: FROM po_bc_distributions
481: WHERE packet_id = x_packet_id
482: AND main_or_backing_code = 'M' ;
483: --
484:

Line 487: -- SQL What: Querying for records in po_bc_distributions

483: --
484:
485: --
486: CURSOR cur_po_bc_dist IS
487: -- SQL What: Querying for records in po_bc_distributions
488: -- SQL Why : Need to group data for same header_id,segment1 and gl date in one event
489: -- SQL Join: None
490: SELECT distinct applied_to_header_id_1, segment1, gl_date,distribution_id,distribution_type
491: FROM po_bc_distributions

Line 491: FROM po_bc_distributions

487: -- SQL What: Querying for records in po_bc_distributions
488: -- SQL Why : Need to group data for same header_id,segment1 and gl date in one event
489: -- SQL Join: None
490: SELECT distinct applied_to_header_id_1, segment1, gl_date,distribution_id,distribution_type
491: FROM po_bc_distributions
492: WHERE packet_id = x_packet_id
493: AND main_or_backing_code = 'M' ; -- Bug #4637958
494: --Bug5187228 Added the below cursor to get the gl_date of the old transactions for the current distribution id
495: --

Line 498: -- SQL What: Querying for records in po_bc_distributions

494: --Bug5187228 Added the below cursor to get the gl_date of the old transactions for the current distribution id
495: -- 496: -- instead of using the package variable>
497: CURSOR cur_po_bc_dist_del(p_distribution_id Number,p_event_type_code VARCHAR2) IS
498: -- SQL What: Querying for records in po_bc_distributions
499: -- SQL Why :
500: -- SQL Join: None
501: SELECT gl_date
502: FROM po_bc_distributions

Line 502: FROM po_bc_distributions

498: -- SQL What: Querying for records in po_bc_distributions
499: -- SQL Why :
500: -- SQL Join: None
501: SELECT gl_date
502: FROM po_bc_distributions
503: WHERE packet_id <> x_packet_id
504: AND distribution_id = p_distribution_id
505: AND ae_event_id is not null
506: AND event_type_code =p_event_type_code --bug#5646605 used a param instead of package variable

Line 534: c_distribution_id PO_BC_DISTRIBUTIONS.distribution_id%TYPE;

530: l_num_of_rows_deleted NUMBER;
531: l_num_of_rows_inserted NUMBER;
532:
533: --
534: c_distribution_id PO_BC_DISTRIBUTIONS.distribution_id%TYPE;
535: c_derive_event_type_code VARCHAR2(1) := 'N';
536: c_event_type_code PO_BC_DISTRIBUTIONS.event_type_code%TYPE;
537: c_main_or_backing_code PO_BC_DISTRIBUTIONS.main_or_backing_code%TYPE;
538: c_packet_id PO_BC_DISTRIBUTIONS.packet_id%TYPE;

Line 536: c_event_type_code PO_BC_DISTRIBUTIONS.event_type_code%TYPE;

532:
533: --
534: c_distribution_id PO_BC_DISTRIBUTIONS.distribution_id%TYPE;
535: c_derive_event_type_code VARCHAR2(1) := 'N';
536: c_event_type_code PO_BC_DISTRIBUTIONS.event_type_code%TYPE;
537: c_main_or_backing_code PO_BC_DISTRIBUTIONS.main_or_backing_code%TYPE;
538: c_packet_id PO_BC_DISTRIBUTIONS.packet_id%TYPE;
539: --
540: BEGIN

Line 537: c_main_or_backing_code PO_BC_DISTRIBUTIONS.main_or_backing_code%TYPE;

533: --
534: c_distribution_id PO_BC_DISTRIBUTIONS.distribution_id%TYPE;
535: c_derive_event_type_code VARCHAR2(1) := 'N';
536: c_event_type_code PO_BC_DISTRIBUTIONS.event_type_code%TYPE;
537: c_main_or_backing_code PO_BC_DISTRIBUTIONS.main_or_backing_code%TYPE;
538: c_packet_id PO_BC_DISTRIBUTIONS.packet_id%TYPE;
539: --
540: BEGIN
541: IF g_debug_stmt THEN

Line 538: c_packet_id PO_BC_DISTRIBUTIONS.packet_id%TYPE;

534: c_distribution_id PO_BC_DISTRIBUTIONS.distribution_id%TYPE;
535: c_derive_event_type_code VARCHAR2(1) := 'N';
536: c_event_type_code PO_BC_DISTRIBUTIONS.event_type_code%TYPE;
537: c_main_or_backing_code PO_BC_DISTRIBUTIONS.main_or_backing_code%TYPE;
538: c_packet_id PO_BC_DISTRIBUTIONS.packet_id%TYPE;
539: --
540: BEGIN
541: IF g_debug_stmt THEN
542: PO_DEBUG.debug_begin(l_log_head);

Line 571: -- Insert the data into PO_BC_DISTRIBUTIONS from PO_ENCUMBRANCE_GT,

567: l_login_id := FND_GLOBAL.login_id ;
568:
569:
570:
571: -- Insert the data into PO_BC_DISTRIBUTIONS from PO_ENCUMBRANCE_GT,
572: --bug#5523323 Modified the insert statement to fetch data directly
573: --from the po_encumbrance_gt table rather than collections. This
574: --is possible because the autonomous transaction no longer exists.
575: INSERT INTO PO_BC_DISTRIBUTIONS

Line 575: INSERT INTO PO_BC_DISTRIBUTIONS

571: -- Insert the data into PO_BC_DISTRIBUTIONS from PO_ENCUMBRANCE_GT,
572: --bug#5523323 Modified the insert statement to fetch data directly
573: --from the po_encumbrance_gt table rather than collections. This
574: --is possible because the autonomous transaction no longer exists.
575: INSERT INTO PO_BC_DISTRIBUTIONS
576: ( BC_DISTRIBUTION_ID,
577: PACKET_ID,
578: STATUS_CODE,
579: CREATION_DATE,

Line 635: PO_BC_DISTRIBUTIONS_S.nextval,

631: ADJUSTMENT_STATUS,
632: ORIGIN_SEQUENCE_NUM
633: )
634: SELECT
635: PO_BC_DISTRIBUTIONS_S.nextval,
636: x_packet_id,
637: p_status_code,
638: SYSDATE,
639: p_user_id,

Line 699: --between po_bc_distributions and xla_distribution_links. A 1-1 mapping

695: l_progress := '100';
696: --
697: --We need to set the value of APPLIED_TO_DIST_ID_2 this would be passed
698: --onto the allocation attributes so that a 1-1 mapping can be created
699: --between po_bc_distributions and xla_distribution_links. A 1-1 mapping
700: --already exists between xla_distribution_links and gl_bc_packets. This
701: --is the route to be followed to establish a 1-1 mapping between
702: --po_bc_distributions and xla_distribution_links
703: l_num_of_rows_inserted :=sql%rowcount;

Line 702: --po_bc_distributions and xla_distribution_links

698: --onto the allocation attributes so that a 1-1 mapping can be created
699: --between po_bc_distributions and xla_distribution_links. A 1-1 mapping
700: --already exists between xla_distribution_links and gl_bc_packets. This
701: --is the route to be followed to establish a 1-1 mapping between
702: --po_bc_distributions and xla_distribution_links
703: l_num_of_rows_inserted :=sql%rowcount;
704: IF g_debug_stmt THEN
705: PO_DEBUG.debug_var(l_log_head,l_progress,'l_num_of_rows_inserted',l_num_of_rows_inserted);
706: END IF;

Line 737: po_bc_distributions pbd1, -- for Backing

733:
734: SELECT prd.distribution_id
735: INTO c_distribution_id
736: FROM po_req_distributions_all prd,
737: po_bc_distributions pbd1, -- for Backing
738: po_bc_distributions pbd2 -- For Main
739: WHERE pbd1.packet_id = x_packet_id
740: AND prd.distribution_id = pbd1.distribution_id
741: AND prd.source_req_distribution_id IS NOT NULL

Line 738: po_bc_distributions pbd2 -- For Main

734: SELECT prd.distribution_id
735: INTO c_distribution_id
736: FROM po_req_distributions_all prd,
737: po_bc_distributions pbd1, -- for Backing
738: po_bc_distributions pbd2 -- For Main
739: WHERE pbd1.packet_id = x_packet_id
740: AND prd.distribution_id = pbd1.distribution_id
741: AND prd.source_req_distribution_id IS NOT NULL
742: AND pbd1.main_or_backing_code = 'B_REQ'

Line 759: UPDATE po_bc_distributions pbd

755: END IF;
756:
757: IF ( c_distribution_id IS NOT NULL ) THEN
758:
759: UPDATE po_bc_distributions pbd
760: SET main_or_backing_code = 'M' ,event_type_code = 'REQ_RESERVED' , origin_sequence_num = NULL ,
761: entered_amt = entered_amt * -1 ,accounted_amt = accounted_amt * -1
762: WHERE pbd.packet_id = x_packet_id
763: AND pbd.main_or_backing_code = 'B_REQ'

Line 777: UPDATE PO_BC_DISTRIBUTIONS PBD

773: --
774: --
775: -- Performance fix : Also added packet id filter in the inner query to
776: -- avoid a full table scan and to use index based on packet id.
777: UPDATE PO_BC_DISTRIBUTIONS PBD
778: SET PBD.line_number = PBD.bc_distribution_id,
779: PBD.APPLIED_TO_DIST_ID_2=
780: (
781: SELECT ORIG.distribution_id

Line 782: FROM PO_BC_DISTRIBUTIONS ORIG

778: SET PBD.line_number = PBD.bc_distribution_id,
779: PBD.APPLIED_TO_DIST_ID_2=
780: (
781: SELECT ORIG.distribution_id
782: FROM PO_BC_DISTRIBUTIONS ORIG
783: WHERE ORIG.sequence_number=PBD.origin_sequence_num
784: AND ORIG.packet_id = x_packet_id
785: )
786: WHERE PBD.packet_id = x_packet_id ;

Line 824: -- Loop for all distributions in po_bc_distributions for generation of event ids

820: l_event_number := NULL;
821: l_valuation_method := NULL;
822:
823: l_progress := '140' ;
824: -- Loop for all distributions in po_bc_distributions for generation of event ids
825:
826:
827: FOR rec_po_bc_dist IN cur_po_bc_dist
828: LOOP

Line 836: -- If event type code exists on the PO_BC_DISTRIBUTIONS then it will be a backing requisition which we updated

832: l_event_source_info.ledger_id := l_ledger_id;
833: --
834: l_event_source_info.entity_type_code := get_entity_type_code(rec_po_bc_dist.distribution_type,p_action);
835: --
836: -- If event type code exists on the PO_BC_DISTRIBUTIONS then it will be a backing requisition which we updated
837: -- before as the main document. Other all records will have null as this field.
838: SELECT EVENT_TYPE_CODE INTO c_event_type_code
839: FROM PO_BC_DISTRIBUTIONS
840: WHERE packet_id = x_packet_id

Line 839: FROM PO_BC_DISTRIBUTIONS

835: --
836: -- If event type code exists on the PO_BC_DISTRIBUTIONS then it will be a backing requisition which we updated
837: -- before as the main document. Other all records will have null as this field.
838: SELECT EVENT_TYPE_CODE INTO c_event_type_code
839: FROM PO_BC_DISTRIBUTIONS
840: WHERE packet_id = x_packet_id
841: AND distribution_id = rec_po_bc_dist.distribution_id
842: and rownum = 1; -- IR ISO ER 7410448
843: PO_DEBUG.debug_var(l_log_head,l_progress,'Event_type_code Exists : ',c_event_type_code);

Line 902: FROM PO_BC_DISTRIBUTIONS

898: IF g_debug_stmt THEN
899: PO_DEBUG.debug_var(l_log_head,l_progress,'l_old_event_id ',l_old_event_id) ;
900: END IF;
901: DELETE
902: FROM PO_BC_DISTRIBUTIONS
903: WHERE ae_event_id = l_old_event_id
904: AND packet_id <> x_packet_id
905: AND applied_to_header_id_1 = rec_po_bc_dist.applied_to_header_id_1;
906:

Line 976: FROM PO_BC_DISTRIBUTIONS

972: PO_DEBUG.debug_var(l_log_head,l_progress,'l_old_event_id ',l_old_event_id) ;
973: END IF;
974:
975: DELETE
976: FROM PO_BC_DISTRIBUTIONS
977: WHERE ae_event_id = l_old_event_id
978: AND packet_id <> x_packet_id
979: AND applied_to_header_id_1 = rec_po_bc_dist.applied_to_header_id_1;
980:

Line 1023: -- Stamp eventid onto corresponding records in po_bc_distributions

1019: l_event_id:=l_old_event_id;
1020: end if;
1021: --
1022: END IF;
1023: -- Stamp eventid onto corresponding records in po_bc_distributions
1024: IF g_debug_stmt THEN
1025: PO_DEBUG.debug_var(l_log_head,l_progress,'l_event_id ',l_event_id );
1026: PO_DEBUG.debug_var(l_log_head,l_progress,'rec_po_bc_dist.applied_to_header_id_1',rec_po_bc_dist.applied_to_header_id_1);
1027: PO_DEBUG.debug_var(l_log_head,l_progress,'rec_po_bc_dist.gl_date',rec_po_bc_dist.gl_date);

Line 1033: UPDATE po_bc_distributions

1029: l_progress := '160';
1030: --
1031: IF(l_event_id IS NOT NULL)THEN
1032: -- Updating Main distributions
1033: UPDATE po_bc_distributions
1034: SET ae_event_id = l_event_id,
1035: event_type_code=l_event_type_code --bug#5646605 update the event type code for the main doc rows
1036: WHERE packet_id = x_packet_id
1037: AND applied_to_header_id_1 = rec_po_bc_dist.applied_to_header_id_1

Line 1055: UPDATE po_bc_distributions pobd

1051: --
1052: --Update the event_type_code and entity_type_code from main distribution
1053: --onto the backing distribution
1054: FORALL i IN 1..l_seq_num_tbl.count
1055: UPDATE po_bc_distributions pobd
1056: SET pobd.ae_event_id = l_event_id,
1057: pobd.event_type_code=l_event_type_code --bug#5646605 update the event type code for the backing rows
1058: WHERE pobd.packet_id = x_packet_id
1059: AND pobd.origin_sequence_num = l_seq_num_tbl(i);

Line 1064: FROM po_bc_distributions pobd1

1060: --
1061: -- Performance Fix: Simplified the query by Removing inner query
1062: /* AND pobd.distribution_id IN (
1063: SELECT pobd1.distribution_id
1064: FROM po_bc_distributions pobd1
1065: WHERE pobd1.origin_sequence_num = l_seq_num_tbl(i)
1066: ); */
1067: --
1068: --

Line 1246: -- Delete records from po_bc_distributions

1242: OR l_status_code IN ('FATAL', 'XLA_ERROR', 'XLA_NO_JOURNAL' ) -- Bug 5009730
1243: )
1244: THEN
1245: l_progress := '125';
1246: -- Delete records from po_bc_distributions
1247: --bug#5523323 once we remove the autonomous txn we don't have to explicity delete
1248: --data from po_bc_distributions.
1249: --Delete_PO_BC_Distributions(p_packet_id => p_packet_id); -- Bug #4637958
1250:

Line 1248: --data from po_bc_distributions.

1244: THEN
1245: l_progress := '125';
1246: -- Delete records from po_bc_distributions
1247: --bug#5523323 once we remove the autonomous txn we don't have to explicity delete
1248: --data from po_bc_distributions.
1249: --Delete_PO_BC_Distributions(p_packet_id => p_packet_id); -- Bug #4637958
1250:
1251: l_progress := '130';
1252: RAISE g_GL_FUNDS_API_EXC;

Line 1249: --Delete_PO_BC_Distributions(p_packet_id => p_packet_id); -- Bug #4637958

1245: l_progress := '125';
1246: -- Delete records from po_bc_distributions
1247: --bug#5523323 once we remove the autonomous txn we don't have to explicity delete
1248: --data from po_bc_distributions.
1249: --Delete_PO_BC_Distributions(p_packet_id => p_packet_id); -- Bug #4637958
1250:
1251: l_progress := '130';
1252: RAISE g_GL_FUNDS_API_EXC;
1253: END IF;

Line 1360: --po_bc_distributions and gl_bc_packets. We need a distinct to ensure that

1356: --This is so that the error rows are always found. GL moves
1357: --all errored rows to gl_bc_packets_hist for performance reasons.
1358: --
1359: --We have to join with xla_distribution_links to get a mapping between
1360: --po_bc_distributions and gl_bc_packets. We need a distinct to ensure that
1361: --for federal /customization cases where there could be multiple rows in
1362: --gl_bc_packets for the same distribution po_bc_distributions we are returned
1363: --just one row.
1364: --

Line 1362: --gl_bc_packets for the same distribution po_bc_distributions we are returned

1358: --
1359: --We have to join with xla_distribution_links to get a mapping between
1360: --po_bc_distributions and gl_bc_packets. We need a distinct to ensure that
1361: --for federal /customization cases where there could be multiple rows in
1362: --gl_bc_packets for the same distribution po_bc_distributions we are returned
1363: --just one row.
1364: --
1365: -- We will get all the packets id from gl_bc_packets for the events which we have populated in
1366: -- psa_bc_xla_events_gt table for the current packet Id. We won't use the packet id returned by

Line 1404: PO_BC_DISTRIBUTIONS PBD,

1400: pbd.distribution_type) *
1401: PBD.accounted_amt TRANSACTION_AMOUNT,
1402: PBD.reference15 REFERENCE15
1403: FROM XLA_DISTRIBUTION_LINKS XLD,
1404: PO_BC_DISTRIBUTIONS PBD,
1405: GL_BC_PACKETS GLBC
1406: WHERE GLBC.PACKET_ID IN (SELECT DISTINCT glbc1.packet_id
1407: FROM psa_bc_xla_events_gt ps_ev_Gt ,
1408: GL_BC_PACKETS glbc1

Line 1439: PO_BC_DISTRIBUTIONS PBD,

1435: pbd.distribution_type) *
1436: PBD.accounted_amt TRANSACTION_AMOUNT,
1437: PBD.reference15 REFERENCE15
1438: FROM XLA_DISTRIBUTION_LINKS XLD,
1439: PO_BC_DISTRIBUTIONS PBD,
1440: GL_BC_PACKETS_HISTS GLBCH
1441: WHERE GLBCH.PACKET_ID IN (SELECT DISTINCT glbch1.packet_id
1442: FROM psa_bc_xla_events_gt ps_ev_Gt ,
1443: GL_BC_PACKETS_HISTS glbch1

Line 4058: --Name: DELETE_PO_BC_DISTRIBUTIONS

4054: --
4055:
4056: -------------------------------------------------------------------------------
4057: --Start of Comments
4058: --Name: DELETE_PO_BC_DISTRIBUTIONS
4059: --Pre-reqs:
4060: -- None.
4061: --Modifies:
4062: -- PO_BC_DISTRIBUTIONS.

Line 4062: -- PO_BC_DISTRIBUTIONS.

4058: --Name: DELETE_PO_BC_DISTRIBUTIONS
4059: --Pre-reqs:
4060: -- None.
4061: --Modifies:
4062: -- PO_BC_DISTRIBUTIONS.
4063: --Locks:
4064: -- None.
4065: --Function:
4066: -- This procedure deletes from po_bc_distributions all rows corresponding to

Line 4066: -- This procedure deletes from po_bc_distributions all rows corresponding to

4062: -- PO_BC_DISTRIBUTIONS.
4063: --Locks:
4064: -- None.
4065: --Function:
4066: -- This procedure deletes from po_bc_distributions all rows corresponding to
4067: -- a specified packetid.
4068: --Parameters:
4069: --IN:
4070: -- p_packet_id.

Line 4077: -- This procedure deletes from po_bc_distributions all rows corresponding to

4073: --OUT:
4074: -- None.
4075: --Notes:
4076: -- The algorithm of the procedure is as follows :
4077: -- This procedure deletes from po_bc_distributions all rows corresponding to
4078: -- a specified packetid.
4079: --Testing:
4080: --
4081: --End of Comments

Line 4083: PROCEDURE Delete_PO_BC_Distributions (

4079: --Testing:
4080: --
4081: --End of Comments
4082: -------------------------------------------------------------------------------
4083: PROCEDURE Delete_PO_BC_Distributions (
4084: p_packet_id IN NUMBER
4085: )
4086: IS
4087: BEGIN

Line 4089: -- Delete all records for the packet processed from po_bc_distributions

4085: )
4086: IS
4087: BEGIN
4088:
4089: -- Delete all records for the packet processed from po_bc_distributions
4090: DELETE FROM po_bc_distributions
4091: WHERE packet_id = p_packet_id;
4092:
4093: END Delete_PO_BC_Distributions;

Line 4090: DELETE FROM po_bc_distributions

4086: IS
4087: BEGIN
4088:
4089: -- Delete all records for the packet processed from po_bc_distributions
4090: DELETE FROM po_bc_distributions
4091: WHERE packet_id = p_packet_id;
4092:
4093: END Delete_PO_BC_Distributions;
4094:

Line 4093: END Delete_PO_BC_Distributions;

4089: -- Delete all records for the packet processed from po_bc_distributions
4090: DELETE FROM po_bc_distributions
4091: WHERE packet_id = p_packet_id;
4092:
4093: END Delete_PO_BC_Distributions;
4094:
4095: --
4096: -------------------------------------------------------------------------------
4097: --Start of Comments

Line 4102: -- PO_BC_DISTRIBUTIONS.

4098: --Name: populate_bc_report_id
4099: --Pre-reqs:
4100: -- None.
4101: --Modifies:
4102: -- PO_BC_DISTRIBUTIONS.
4103: --Locks:
4104: -- None.
4105: --Function:
4106: -- This procedure populates online_report_id on po_bc_distributions rows corresponding to

Line 4106: -- This procedure populates online_report_id on po_bc_distributions rows corresponding to

4102: -- PO_BC_DISTRIBUTIONS.
4103: --Locks:
4104: -- None.
4105: --Function:
4106: -- This procedure populates online_report_id on po_bc_distributions rows corresponding to
4107: -- a given encumbrance transaction.
4108: --Parameters:
4109: --IN:
4110: -- p_online_report_id.

Line 4119: -- their counterparts in po_bc_distributions with online_report_id

4115: -- None.
4116: --Notes:
4117: -- The algorithm of the procedure is as follows :
4118: -- Get all distributions in the global temporary table and populate
4119: -- their counterparts in po_bc_distributions with online_report_id
4120: --Testing:
4121: --
4122: --End of Comments
4123: -------------------------------------------------------------------------------

Line 4141: PO_BC_DISTRIBUTIONS

4137: End If;
4138: --bug#5523323 Remove the call to populate_aut_bc_report_id as this is not necessary.
4139: --we have removed the autonomous transaction.
4140: UPDATE
4141: PO_BC_DISTRIBUTIONS
4142: SET online_report_id=p_online_report_id
4143: WHERE reference15 in
4144: (
4145: SELECT reference15

Line 4203: -- Populate all rows in po_bc_distributions matching the reference15 column with

4199: --OUT:
4200: -- None.
4201: --Notes:
4202: -- The algorithm of the procedure is as follows :
4203: -- Populate all rows in po_bc_distributions matching the reference15 column with
4204: -- p_online_report_id
4205: --Testing:
4206: --
4207: --End of Comments