Fields: SELNGUOM, PRCHSUOM, UOFM -Dynamics GP Units of measure, a developer perspective
Developers new to ERP or GP can find units of measure a new concept to keep in mind when coding. For some it forms a mental barrier, which is a great pity as its all very simple really!
Units of measure need to be recorded against both inbound and outbound transactions that interact with stock, examples include purchase orders, goods receipts, returns, sales orders, inventory movements, manufacturing orders, bills of material etc. Otherwise we can’t keep track of what has been bought, sold and how much is sitting in inventory. Why? -Lets consider some simple scenarios:
- Company buys metal aluminium extrusion by the Kilogram (Kg) from the mill and sells it in metres(m) to their customer
- Company buys packs of 10 bolts but sells them in single bolts to their customer for spares
- Company buys individual loud speaker horns from the supplier and sells them in pairs to the customer
So buying “1 unit” weight of aluminium extrusion from our first example, and then selling “1 unit” of aluminium length does not mean you have sold one 1kg by selling 1m. Without introducing a conversion factor in the middle you can’t total up what you have left. [more]
Buying and selling units of measure
To operate with the above we need to know what units we are selling things in and what units we are buying things in hence we need to record:
- A Buying unit of measure (often denoted in database as SELNGUOM, char 9)
- A Selling unit of measure (often denoted in database as PRCHSUOM , char 9)
Buying and selling units of measure are found recorded throughout transaction tables that relate to item quantities, such as sales order lines and purchase order lines. These fields allows define what unit of measure the quantities in that document row relate to.
Unit of measure schedules
Great, but packs could contain different numbers of items depending on the nature of the item or perhaps different weights. One pack of toilet rolls will not contain the same number of items as a pack of razor blades hence one pack does not define a containing quantity. Dynamics GP needs a way to know for any item how many should be in a pack/case/pallet/crate etc. This is done by declaring the relationship between units of measure and giving that relationship definition a name to reference it by. Simply declare the relationship, for example, “pack equals two of each”, or for another of the above examples, “one pack equals 10 of each”.
This declaration of the relationships between units of measure for an item is stored in something called the “unit of measure schedule”. This is simply a record of relationships. Every item needs to be assigned a unit of measure schedule. The unit of measure schedule then lets Dynamics GP know what are valid units of measure for that item are and importantly how they relate to each other.
…and base unit of measure
There is final basic concept to grasp. When a user wants to know how many of something is in inventory, they would typically go to find out in stock level enquiry. This window shows the items by location and how many are expected to be there, after adding all goods in and subtracting all goods out. However, we need to introduce the third in the trio, that of “Base Unit Of Measure”.
The values shown in stock enquiry are shown in the base unit of measure for that item. The base unit of measure is the chosen unit of measure that is then used to keep track in inventory of the stock movements of that item. By chosen unit, this simply means whoever set the item up decided this would be the most appropriate unit to use to keep track of inventory. All movements of stock are divided down or multiplied up from that base unit quantity to get to the other units of measure quantities that exist in the unit of measure schedule attached to that item.
Usually the smallest stocking unit is used as the base unit of measure. Sometimes it is simply the unit that “makes sense” to the business that is used, the unit that is familiar to the users. To illustrate this in an example, if the base unit of measure were PAIR and we adjusted 1 PAIR out of stock, one would be subtracted from the stock figure. Should the base unit of measure had been EACH and 1 PAIR had been transferred from stock, 2 would be subtracted from stock.
All qtys in enquiry are in the base unit of measure.
Qty in Base Unit of Measure
Just as the unit of measure used in a transaction is recorded, the multiplier for the quantity is also recorded. All transaction lines such as sales document lines contain a figure in a field called QTYBSUOM (numeric 19,5), “Qty in Base U of M” that states for that item how many to multiply by to get to the base unit of measure. This avoids the need to join back to the unit of measure schedule tables each time this information is needed.
Example of sales line and quantity removed from inventory on sale
|QUANTITY||QTYBSUOM||Qty removed from Base unit of measure on posting invoice|
The number of decimal places to be used in recording quantities is also set up in the unit of measure schedule. This is held in the field UMDPQTYS –note one must be subtracted from this value to obtain the number of decimal places.
Unit of measure schedule definition