A/P Freight Reconcile for Multi-Site Companies

A/P Freight Reconcile for Multi-Site Companies

A few things about this query:
– Replace the ‘XXXX-XX-XX’ with a date range of the financial period you are closing

select

(select TOP 1 x.locncode from pop30310 x where x.ponumber = a.pordnmbr) [Site],

a.VENDORID [Vendor ID], a.docdate [Invoice Date], a.POSTEDDT [Posted Date], a.DOCNUMBR [Invoice], a.pordnmbr [PO Number], a.DOCAMNT [Order Amount], a.frtamnt [Freight Amount]

from pm30200 a

where

a.POSTEDDT between ‘XXXX-XX-XX’ and ‘XXXX-XX-XX’

and a.DOCTYPE = ‘1’