R12: Quaries
  Find a query which fetches both invoice and prepayment information of a payable invoice:     SELECT  pv . vendor_name "Vendor Name" ,          ai . invoice_num "Invoice Num" ,          ai . invoice_id "Invoice Id" ,          ai . invoice_amount "Invoice amount" ,          ail . line_number "Invoice Line Num" ,          ai2 . invoice_id "Prepay Invoice Id" ,          ai2 . invoice_num "Prepay Invoice Num" ,          ail . prepay_line_number "Prepay Invoice Line Num" ,          (- 1 )*( ail . amount -  NVL ( ail . included_tax_amount , 0 ))           "Prepay Amount Applied" ,          NULLIF ((- 1 )*( NVL ( ail . total_rec_tax_amount ,  0 )  +               ...