1. select pv.vendor_name, pv.vendor_name_alt, pv.vendor_type_lookup_code, pv.segment1 vendor_number , pvsa.vendor_site_code, pvsa.vendor_site_code_alt, pvsa.address_line1, pvsa.address_line2, pvsa.address_line3 , pvsa.city, pvsa.state, pvsa.zip, pvsa.province, pvsa.country, pvsa.pay_group_lookup_code, pvsa.org_id , pvsa.global_attribute18 legacy_related1, pvsa.global_attribute19 legacy_related2, pvsa.global_attribute20 legacy , pv.vendor_id vendor_id, pvsa.vendor_site_id vendor_site_id from po_vendors pv , po_vendor_sites pvsa where pv.vendor_id = pvsa.vendor_id(+) --and pv.vendor_name like 'TTS CARGO%' 2. select pv.vendor_name, pv.vendor_name_alt, pv.vendor_type_lookup_code, pv.segment1 vendor_number , aia.invoice_num, aia.invoice_date, aia.source -- pvsa.vendor_site_code, , aia.invoice_type_lookup_code, aia.description, aia.attribute1 document, aia.attribute2, aia.attribute4 port , aia.attribute5 Portofdischarge, aia.attribute7 call_date, aia.attribute11 costcenter, aia.attribute12 site , aia.attribute9 Principal, aia.doc_sequence_value document_number, aia.vendor_site_id vendor_site_id , aia.org_id from po_vendors pv , ap_invoices aia --po_vendor_sites_all pvsa, where pv.vendor_id = aia.vendor_id and (aia.amount_paid != aia.invoice_amount or aia.amount_paid is null) and aia.cancelled_date is null --and pvsa.vendor_site_id = aia.vendor_site_id(+) --and pv.vendor_name like 'TTS CARGO%' --= 'TTS CARGO.' --