3898: pll.matching_basis,
3899: Nvl(pdsh.clm_flag,'N') clm_flag
3900: FROM
3901: --po_distributions_all pod,
3902: po_line_locations_all pll,
3903: po_lines_all pl,
3904: po_headers_all ph,
3905: rcv_shipment_lines rsl,
3906: rcv_shipment_headers rsh,
5308:
5309: FUNCTION GET_ORDERED_AMOUNT (p_wc_id IN NUMBER)
5310: RETURN number IS
5311: l_count number;
5312: l_amount po_line_locations_all.amount%type;
5313: begin
5314:
5315: select count(*)
5316: into l_count
5313: begin
5314:
5315: select count(*)
5316: into l_count
5317: from po_line_locations_all poll
5318: where poll.line_location_id = p_wc_id
5319: and nvl(poll.matching_basis,'QUANTITY')='AMOUNT';
5320:
5321:
5324: else
5325:
5326: select poll.amount
5327: into l_amount
5328: from po_line_locations_all poll
5329: where poll.line_location_id = p_wc_id
5330: and nvl(poll.matching_basis,'QUANTITY')='AMOUNT';
5331:
5332:
5337:
5338: FUNCTION GET_ORDERED_QUANTITY (p_wc_id IN NUMBER)
5339: RETURN number IS
5340: l_count number;
5341: l_quantity po_line_locations_all.quantity%type;
5342: begin
5343:
5344: select count(*)
5345: into l_count
5342: begin
5343:
5344: select count(*)
5345: into l_count
5346: from po_line_locations_all poll
5347: where poll.line_location_id = p_wc_id
5348: and nvl(poll.matching_basis,'QUANTITY')='QUANTITY';
5349:
5350:
5353: else
5354:
5355: select poll.quantity
5356: into l_quantity
5357: from po_line_locations_all poll
5358: where poll.line_location_id = p_wc_id
5359: and nvl(poll.matching_basis,'QUANTITY')='QUANTITY';
5360:
5361: