PO Dumps Extraction

SELECT pov.segment1 supplier_number, povs.vendor_site_code supplier_site,
pov.vendor_name supplier_name, poh.segment1 po_number,
hrls.location_code ship_to_location, poh.currency_code,
hrlb.location_code bill_to_location, poh.comments header_desc,
poh.creation_date po_date, poh.authorization_status approval_status,
pol.line_num po_line_no, pol.purchase_basis line_type,
pp.segment1 project_code, pt.task_number task_code, expenditure_type,
msib.segment1 item_code, msib.primary_uom_code uom, pol.quantity,
pol.unit_price rate, poll.need_by_date,
ood.organization_code ship_to_org_code,
gcc.concatenated_segments charge_account, gl_encumbered_date gl_date,
ou.NAME ou_name, ppf.full_name buyer,
gcc1.concatenated_segments accrual_account, poh.rate_type,
poh.rate_date, poh.rate exchange_rate, pol.note_to_vendor po_line_desc
–poh.ATTRIBUTE15
FROM po_headers_all poh,
po_lines_all pol,
gl_code_combinations_kfv gcc,
gl_code_combinations_kfv gcc1,
mtl_system_items_b msib,
po_line_locations_all poll,
po_distributions_all pod,
org_organization_definitions ood,
po_vendors pov,
po_vendor_sites_all povs,
hr_locations_all hrls,
hr_locations_all hrlb,
per_all_people_f ppf,
po_line_types polt,
pa_projects_all pp,
pa_tasks pt,
hr_operating_units ou
WHERE 1 = 1
AND poh.bill_to_location_id = hrlb.location_id
AND polt.line_type_id = pol.line_type_id
AND povs.vendor_site_id = poh.vendor_site_id
AND pov.vendor_id = poh.vendor_id
AND pol.item_id = msib.inventory_item_id
AND msib.organization_id = poll.ship_to_organization_id
AND pod.code_combination_id = gcc.code_combination_id
AND pod.accrual_account_id = gcc1.code_combination_id
AND poll.ship_to_organization_id = ood.organization_id
AND poh.po_header_id = pol.po_header_id
AND pol.po_line_id = pod.po_line_id
AND poll.line_location_id = pod.line_location_id
AND poh.ship_to_location_id = hrls.location_id
AND poh.agent_id = ppf.person_id
AND pod.project_id = pp.project_id(+)
AND pod.task_id = pt.task_id(+)
AND poh.org_id = ou.organization_id
AND poh.attribute15 = ‘Open PO Migration’
and trunc(pol.creation_Date)=trunc(sysdate)
— and ou.name=’xxxxx’
— and trunc(poh.last_update_Date)=’14-Nov-19′
— AND poh.segment1 LIKE ‘TEC/IT/199/19%’
— and poh.segment1=’17286′
— and poh.comments is null
–and currency_code!=’AED’
order by po_number,po_line_no

Recent Posts