DBA Data[Home] [Help]

APPS.INV_RCV_COMMON_APIS dependencies on PO_LINE_LOCATIONS

Line 1975: * Routing ID is defined at PO line-location level (po_line_locations_all)

1971:
1972: /*************************************************
1973: * Name: get_po_routing_id
1974: * This API returns routing id for a given PO header ID
1975: * Routing ID is defined at PO line-location level (po_line_locations_all)
1976: * We use the following rule to set headers routing ID
1977: * If there is one line detail needs inspection the entire PO needs inspection
1978: * elsif there is one line detail needs direct receiving the entire PO direct
1979: * else (all line detail are standard) the entire PO is standard

Line 2009: FROM po_line_locations poll, po_lines pol

2005: -- searching mechanism will not
2006: -- go to item/org level.
2007: SELECT poll.receiving_routing_id
2008: -- p_po_release_id is null and p_po_line_id is null
2009: FROM po_line_locations poll, po_lines pol
2010: WHERE pol.po_header_id = p_po_header_id
2011: AND poll.po_line_id = pol.po_line_id
2012: AND p_po_release_id is NULL
2013: AND p_po_line_id is null

Line 2024: FROM po_line_locations poll, po_lines pol

2020: AND poll.shipment_type IN('STANDARD', 'BLANKET', 'SCHEDULED')
2021: UNION ALL
2022: SELECT poll.receiving_routing_id
2023: -- p_po_release_id is null and p_po_line_id is not null
2024: FROM po_line_locations poll, po_lines pol
2025: WHERE poll.po_header_id = p_po_header_id
2026: AND poll.po_line_id = pol.po_line_id
2027: AND p_po_release_id is NULL
2028: AND (p_po_line_id is not null AND poll.po_line_id = p_po_line_id)

Line 2039: FROM po_line_locations poll, po_lines pol

2035: AND poll.shipment_type IN('STANDARD', 'BLANKET', 'SCHEDULED')
2036: UNION ALL
2037: SELECT poll.receiving_routing_id
2038: -- p_po_release_id is not null
2039: FROM po_line_locations poll, po_lines pol
2040: WHERE poll.po_header_id = p_po_header_id
2041: AND poll.po_line_id = pol.po_line_id
2042: AND (p_po_release_id is NOT NULL AND poll.po_release_id = p_po_release_id)
2043: AND (p_po_line_id is null or poll.po_line_id = p_po_line_id)

Line 2053: FROM po_line_locations poll, po_lines pol

2049: /*Fix for bug #4755862*/
2050: AND poll.shipment_type IN('STANDARD', 'BLANKET', 'SCHEDULED');
2051: /*
2052: SELECT poll.receiving_routing_id
2053: FROM po_line_locations poll, po_lines pol
2054: WHERE poll.po_header_id = p_po_header_id
2055: AND NVL(poll.po_release_id, -1) = NVL(p_po_release_id, NVL(poll.po_release_id, -1))
2056: AND NVL(poll.po_line_id, -1) = NVL(p_po_line_id, NVL(poll.po_line_id, -1))
2057: --AND pol.item_id = p_item_id

Line 2074: FROM PO_DISTRIBUTIONS POD, PO_LINES POL, PO_LINE_LOCATIONS POLL

2070:
2071: CURSOR pod_dest_context_cur IS
2072: SELECT DISTINCT NVL(POD.DESTINATION_TYPE_CODE,POD.DESTINATION_CONTEXT)
2073: -- p_po_release_id is null and p_po_line_id is null
2074: FROM PO_DISTRIBUTIONS POD, PO_LINES POL, PO_LINE_LOCATIONS POLL
2075: WHERE POL.PO_HEADER_ID = p_po_header_id
2076: AND POLL.PO_LINE_ID = POL.PO_LINE_ID
2077: AND POD.LINE_LOCATION_ID = POLL.LINE_LOCATION_ID
2078: AND p_po_release_id is NULL

Line 2089: FROM PO_DISTRIBUTIONS POD, PO_LINES POL, PO_LINE_LOCATIONS POLL

2085: AND POLL.SHIPMENT_TYPE IN ( 'STANDARD','BLANKET','SCHEDULED' )
2086: UNION ALL
2087: SELECT DISTINCT NVL(POD.DESTINATION_TYPE_CODE,POD.DESTINATION_CONTEXT)
2088: -- p_po_release_id is null and p_po_line_id is not null
2089: FROM PO_DISTRIBUTIONS POD, PO_LINES POL, PO_LINE_LOCATIONS POLL
2090: WHERE POLL.PO_HEADER_ID = p_po_header_id
2091: AND POLL.PO_LINE_ID = POL.PO_LINE_ID
2092: AND POD.LINE_LOCATION_ID = POLL.LINE_LOCATION_ID
2093: AND p_po_release_id is NULL

Line 2104: FROM PO_DISTRIBUTIONS POD, PO_LINES POL, PO_LINE_LOCATIONS POLL

2100: AND POLL.SHIPMENT_TYPE IN ( 'STANDARD','BLANKET','SCHEDULED' )
2101: UNION ALL
2102: SELECT DISTINCT NVL(POD.DESTINATION_TYPE_CODE,POD.DESTINATION_CONTEXT)
2103: -- p_po_release_id is not NULL
2104: FROM PO_DISTRIBUTIONS POD, PO_LINES POL, PO_LINE_LOCATIONS POLL
2105: WHERE POLL.PO_HEADER_ID = p_po_header_id
2106: AND POLL.PO_LINE_ID = POL.PO_LINE_ID
2107: AND POD.LINE_LOCATION_ID = POLL.LINE_LOCATION_ID
2108: AND (p_po_release_id is NOT NULL AND POLL.PO_RELEASE_ID = p_po_release_id)

Line 2118: FROM po_distributions pod, po_lines pol, po_line_locations poll

2114: AND NVL(POLL.CLOSED_CODE,'OPEN') <> 'FINALLY CLOSED'
2115: AND POLL.SHIPMENT_TYPE IN ( 'STANDARD','BLANKET','SCHEDULED' );
2116: /*
2117: SELECT DISTINCT Nvl(pod.destination_type_code,pod.destination_context)
2118: FROM po_distributions pod, po_lines pol, po_line_locations poll
2119: WHERE pod.po_header_id = p_po_header_id
2120: AND NVL(poll.po_release_id, -1) = NVL(p_po_release_id, NVL(poll.po_release_id, -1))
2121: AND NVL(poll.po_line_id, -1) = NVL(p_po_line_id, NVL(poll.po_line_id, -1))
2122: --AND pol.item_id = p_item_id

Line 3527: FROM po_line_locations_all poll, po_lines_all po

3523: AND pol.unit_meas_lookup_code IS NOT NULL
3524: AND pol.line_num = p_line_no
3525: AND pol.unit_meas_lookup_code = mum.unit_of_measure
3526: AND pol.po_line_id IN (SELECT poll.po_line_id
3527: FROM po_line_locations_all poll, po_lines_all po
3528: WHERE poll.po_header_id = po.po_header_id
3529: AND Nvl(poll.approved_flag,'N') = 'Y'
3530: AND Nvl(poll.cancel_flag,'N') = 'N'
3531: AND Nvl(poll.closed_code,'OPEN') NOT IN ('FINALLY CLOSED','CLOSED FOR RECEIVING')

Line 3564: FROM po_line_locations_all poll, po_lines_all po

3560: AND pol.unit_meas_lookup_code IS NOT NULL
3561: AND pol.unit_meas_lookup_code = mum.unit_of_measure
3562: AND pol.item_description = p_item_desc
3563: AND pol.po_line_id IN (SELECT poll.po_line_id
3564: FROM po_line_locations_all poll, po_lines_all po
3565: WHERE poll.po_header_id = po.po_header_id
3566: AND Nvl(poll.approved_flag,'N') = 'Y'
3567: AND Nvl(poll.cancel_flag,'N') = 'N'
3568: AND Nvl(poll.closed_code,'OPEN') NOT IN ('FINALLY CLOSED','CLOSED FOR RECEIVING')

Line 3602: FROM po_line_locations_all poll, po_lines_all po

3598: WHERE pol.po_header_id = p_po_header_id
3599: AND pol.unit_meas_lookup_code IS NOT NULL
3600: AND pol.item_id = p_item_id
3601: AND pol.po_line_id IN (SELECT poll.po_line_id
3602: FROM po_line_locations_all poll, po_lines_all po
3603: WHERE poll.po_header_id = po.po_header_id
3604: AND Nvl(poll.approved_flag,'N') = 'Y'
3605: AND Nvl(poll.cancel_flag,'N') = 'N'
3606: AND Nvl(poll.closed_code,'OPEN') NOT IN ('FINALLY CLOSED','CLOSED FOR RECEIVING')

Line 3631: FROM po_line_locations_all poll, po_lines_all po

3627: AND pol.unit_meas_lookup_code IS NOT NULL
3628: AND pol.item_id = p_item_id
3629: AND mum.UNIT_OF_MEASURE(+) = pol.UNIT_MEAS_LOOKUP_CODE
3630: AND pol.po_line_id IN (SELECT poll.po_line_id
3631: FROM po_line_locations_all poll, po_lines_all po
3632: WHERE poll.po_header_id = po.po_header_id
3633: AND Nvl(poll.approved_flag,'N') = 'Y'
3634: AND Nvl(poll.cancel_flag,'N') = 'N'
3635: AND Nvl(poll.closed_code,'OPEN') NOT IN ('FINALLY CLOSED','CLOSED FOR RECEIVING')

Line 4194: FROM hr_locations hl, po_line_locations poll,po_lines pol

4190:
4191: IF p_po_header_id IS NOT NULL THEN
4192: SELECT distinct( hl.location_code )
4193: into x_location_code
4194: FROM hr_locations hl, po_line_locations poll,po_lines pol
4195: WHERE hl.location_id = poll.ship_to_location_id
4196: AND poll.po_header_id = p_po_header_id
4197: AND poll.po_line_id = NVL(p_po_line_id, poll.po_line_id)
4198: AND Nvl(pol.item_id,-9999) = NVL(p_item_id,Nvl(pol.item_id,-9999))--BUG 4500676

Line 4317: FROM po_line_locations poll,po_lines pol

4313: END IF;
4314:
4315: SELECT DISTINCT (pol.item_revision)
4316: INTO x_revision_code
4317: FROM po_line_locations poll,po_lines pol
4318: WHERE pol.po_header_id = p_po_header_id
4319: AND NVL(poll.po_line_id,-1) = NVL(p_po_line_id, NVL(poll.po_line_id, -1))
4320: AND NVL(pol.item_id,-1) = NVL(p_item_id,NVL(pol.item_id, -1))
4321: AND poll.ship_to_organization_id= p_organization_id