This is a primer for the transaction flow in Microsoft Dynamics GP (formerly Great Plains).
POs are entered into POP10100 and POP10110
There are three types of receiving docs - Shipments, Shipment/Invoices, and Invoices. Shipments and Shipment invoices are entered directly into the POP10500 through the TRANSACTIONS > PURCHASING > RECEIVINGS TRANSACTION ENTRY form.
Invoices are entered through TRANSACTIONS > PURCHASING > ENTER/MATCH INVOICES. These lines also go into the POP10500 table, and links to the shipment are entered in the POP10600 table. So in this case there is a link from POP10500 (invoice) to POP10600 to POP10500 (shipment)
This query will show all items on order that have outstanding quantities:
select
pol.qtyorder- pol.qtycance- shipments.qtyshppd
as
qtyOnOrder, pol.itemnmbr, pol.itemdesc, pol.uofm
from
pop10100 po
join
pop10110 pol
on
pol.ponumber = po.ponumber
--get the total amount already received
left
join
(
select
ponumber, polnenum,
sum
(qtyshppd)
as
qtyshppd
from
pop10500
group
by
ponumber, polnenum)
shipments
on
shipments.ponumber = pol.ponumber
and
shipments.polnenum = pol.ord
where
pol.qtyorder - pol.qtycance - shipments.qtyshppd > 0
POs are entered via PURCHASING > PURCHASE ORDER ENTRY, into POP10100 and POP10110
RECEIPTS:
There are two types of receipts, SHIPMENT and SHIPMENT/INVOICE
Shipments (when posted) create a line in POP10500 and lines in POP30300 and POP30310
Shipment/Invoices (when posted)...