Find invalid selling units of measure for Microsoft GP

SELECT IV00101.ITEMNMBR
,IV00101.UOMSCHDL
,IV00101.SELNGUOM
,IV40202.*
FROM IV00101
LEFT JOIN IV40201 ON IV00101.UOMSCHDL = IV40201.UOMSCHDL
LEFT JOIN IV40202 ON IV40201.UOMSCHDL = IV40202.UOMSCHDL
AND IV40202.UOFM = IV00101.SELNGUOM
WHERE iv40202.DEX_ROW_ID IS NULL
AND IV00101.SELNGUOM != ''

The above will find any selling unit of measure that are not contained in the item’s unit of measure schedule.

Add comment

Loading