10529: , po_dist.distribution_num
10530: , po_dist.distribution_type
10531: FROM po_headers po
10532: , po_lines po_line
10533: , po_distributions po_dist
10534: WHERE po.po_header_id = po_line.po_header_id
10535: AND po_line.po_line_id = po_dist.po_line_id
10536: AND po_dist.po_distribution_id = p_po_distribution_id;
10537: BEGIN
10731: l_ccid_changed BOOLEAN := FALSE; /* Bug 5440305 */
10732:
10733: CURSOR c_po_shipment_id_cur(p_po_distribution_id NUMBER) IS
10734: SELECT LINE_LOCATION_ID
10735: FROM PO_DISTRIBUTIONS
10736: WHERE PO_DISTRIBUTION_ID = p_po_distribution_id;
10737:
10738: /* Bug 5386471 - Start */
10739: CURSOR c_parent_distribution_id_cur(p_invoice_distribution_id AP_INVOICE_DISTRIBUTIONS_ALL.INVOICE_DISTRIBUTION_ID%TYPE) IS
11163:
11164: CURSOR c_get_accrue_on_receipt_flag IS
11165: SELECT poll.accrue_on_receipt_flag
11166: FROM po_line_locations_all poll
11167: , po_distributions_all pod
11168: , ap_invoice_distributions_all aid
11169: WHERE poll.line_location_id = pod.line_location_id
11170: AND pod.po_distribution_id = aid.po_distribution_id
11171: AND aid.invoice_distribution_id = p_invoice_distribution_id;