987: from po_requisition_lines_all
988: where requisition_line_id = req_line_id;
989:
990: if (cancelled = 'Y') then
991: select to_char(0, fnd_currency.safe_get_format_mask(currency_code, 30))
992: into value
993: from sys.dual;
994: else
995: select prl.unit_price * (prl.quantity - nvl(prl.quantity_cancelled,0))
996: into total
997: from po_requisition_lines_all prl
998: where requisition_line_id = req_line_id;
999:
1000: select to_char(total, fnd_currency.safe_get_format_mask(currency_code, 30))
1001: into value
1002: from sys.dual;
1003: end if;
1004: