Select a production order route based on order quantity in Dynamics AX

When you schedule a production order you often have to set the system up so that it chooses a production resource based upon its availability, but unless your company is making widgets you sometimes have to take into account the order quantity. This is true of more or less any liquid that is produced in fixed container like a reaction vessel or vat.

So first I’ll setup my simple finished goods item with a simple bill of material (one component / ingredient):

You’ll see that I’m working in the ‘New Dynamics AX’ (AX 7 in old money), but everything I’m doing here applies equally to AX 2012 and AX 2009.

Before I can setup my route, I need work centres (resources) and a resource has to be created with a resource group – so I need one of those too. My resource group is called GMIXERS and my work centres are M-BIG and M-SMALL:

Incidentally I noticed a small change here. In AX 2012 you set the resource calendar on the list grid that links the resource to its resource group. In the current version, you setup the resource calendar on the Calendars fast tab.

Next I need an Operation, and Operation relations, and in this case I’m going to setup two routes, first a route that has a resource requirement for my small machine:

Before I set the resource requirement I need to change the Route code from All to Route, and select this route number, because I only want this resource selection to be related to this route (not the other route that I’m going to create next). Then I can choose the recourse I want:

And then another route for my large capacity machine:

Now let’s mosey on over to the item (released product) and setup two route versions, and of course I’m going to set the ‘From quantity’ as needed:

Then I approve and activate the route versions. I can have more than one Active route because of the ‘From quantity’ selection.

The last bit of setup I might need to make is to constrain my order quantities using the Default order settings (or Site specific order settings). Unfortunately, there is no ‘Production’ tab. The Inventory tab is used for the default for inventory transactions (for instance planned transfer orders), as well as production – so it’s quite likely that you will need to compromise here. I’m going to use these default order settings:

Now let’s see if this works. There are a couple of tests I need to make – first is the correct route chosen when I create a production order manually?

All good there, as long as when I change the quantity I click Yes when I see the pop-up message:

I’ve set a safety stock of 500 and master planning has created me two orders for 200 and one for 100:

I can use the Route button to check that the correct route has been selected (or I can use the capacity reservation inquiry):

From the orders for 200 I see:

And of course from the order for 100 I get:

Everything is setup and working as expected – but the Default order settings don’t give us many options for constraining the order quantities for batch production. In this case I deliberately choose my order quantities to be nice round numbers and multiples of each other (100 and 200) – but what if I had three machines with capacities like 1750, 2300 and 4150? There’s no way the Default order settings can give me an order of one of those sizes – and anyway as I said before you might not want to use default order settings to constrain default order quantities – because you might want to use them for inventory (where the default order quantity might represent a carton or pallet – a small part of a production batch).

I thought that there would be a solution using Formulas and Batch production orders – but I couldn’t figure it out at first. Thanks to Colby Gallagher for answering my post on the Dynamics AX Community Forum.

There are more options on the setup of a Formula version (as opposed to a BOM version), specifically there are two additional fields, Formula size and Formula multiple.

It’s actually easier to see the setup I’m using in the AX 2012 list grid – so here it is:

(It turns out that setting the ‘From formula size’ = zero on the first formula version is important to getting this working).

I don’t want master planning to generate planned production orders larger than my largest production vessel but I don’t need to set the minimum or multiple, so my Default order settings are:

Now I just get these specific quantities on my planned orders.

For instance:


Thanks Colby!