PO Expected Receipts

Description
Categories: BI Publisher, Procurement
Application: Purchasing
Source: Expected Receipts Report (XML)
Short Name: POXRVXRV_XML
DB package: PO_POXRVXRV_XMLP_PKG
SELECT TO_CHAR(nvl(pll.promised_date,need_by_date), 'DD/MON/YYYY HH24:MI:SS')            P_Date
,      pov.vendor_name                        Source
,      null                           C_FLEX_ITEM
,      null                            C_FLEX_CAT
,      poh.segment1                              PO_NUM
,     decode(por.release_num,null,null,por.release_num)  PO_REL_NUM
,      pol.line_num                                PO_LINE_NUM
,      poh.segment1||decode(por.release_num,null,null,'-'||por.release_num)||
       ','||pol.line_num                      Number_Release_Line
,      pdt.type_name                   Doc_type
,      pll.shipment_type               Shipment_type 
,      'ABC'                      Location           
,      pll.ship_to_location_id                       Location_id    
,      pol.item_revision                      Rev
,      pol.unit_meas_lookup_code              Unit
,      pol.vendor_product_num                 Product_Number
,      plt.line_type                          Line_Type
,      pol.item_description                   Item_Description
,      decode(nvl(rp.blind_receiving_flag,'N'), 'N',round(pll.quantity,:P_qty_precision), NULL)
Ordered
,      decode(nvl(rp.blind_receiving_flag,'N'), 'N',round(decode(sign(nvl(pll.quantity,0)-nvl(pll.quantity_received,0)),-1,0,0,0,
              +1,nvl(pll.quantity,0)-nvl(pll.quantity_received,0)),:P_qty_precision) ,NULL)  Due
,      poh.note_to_receiver                   Note_receiver
,      phc.hazard_class                       Hazard
,      pun.un_number                          Un_Number
,      pun.description                        Un_Description
,      plc2.displayed_field