Skip to main content
Question

What Sales calculation does Acumatica use in Inventory Planning > Demand forecast Model?

  • September 3, 2026
  • 3 replies
  • 68 views

rkenna
Captain II
Forum|alt.badge.img+4

Hi Community,

I am trying to setup the Inventory Planning for a Stock Item, and I can’t figure out the moving average. Everywhere I read it just says it calculates based on stock quantities, historical sales, and the service level set, but what is the calculation/ what is it looking at when it comes to Historical Sales?

Is it based on Invoice lines? Sales Order lines?
Is it taking into account different Branches?
Is it taking into account Transfer Orders? Returns? Etc.

 

I cannot find any information other than it saying it looks at Historical Sales, and I know it looks back based on the Periods to Analyze, but what is it analyzing in those periods? Does anyone know.

 

Thanks,

RJ

3 replies

Steve Milner
Varsity III
Forum|alt.badge.img+2
  • Varsity III
  • September 3, 2026

@rkenna Short version: it's not reading orders or invoices. It reads released inventory transactions, summed by day for each item and warehouse. So your history is whatever has actually been issued from stock.

To take your questions in order:

Invoice lines or SO lines? Neither. A sale counts when the inventory issue behind the shipment or invoice is released. Open orders and unreleased shipments aren't in the numbers yet.

Branches? No. It's per warehouse. Branch doesn't come into it.

Transfers? Yes, on the way out. A transfer counts as demand at the warehouse it leaves. Transfers in don't offset anything.

Returns? Yes. Credit memo quantity is subtracted from sales.

What's ignored: drop ships, and manual issues or adjustments entered directly on the IN screens.

Now the periods. They're calendar periods, so months start on the 1st. The period your Forecast Date falls in is skipped, and it looks back the number of full periods in Periods to Analyze. Each period becomes a daily rate (total divided by days, scaled by your seasonality factor). The forecast is just the average of those. A period with no sales counts as zero, as long as the item had sold before it.

Safety stock uses the variance of those daily rates and of your PO receipt lead times, times NORMSINV of the service level. Reorder point is lead time × daily demand + safety stock.

This is from the 2026 R1 code.


rkenna
Captain II
Forum|alt.badge.img+4
  • Author
  • Captain II
  • September 11, 2026

Really appreciate the response ​@Steve Milner. Can you please share with me where that 2026R1 code is, and where you found the answers to this inquiry so I can know going forward?

 

Cheers,

RJ


Steve Milner
Varsity III
Forum|alt.badge.img+2
  • Varsity III
  • September 11, 2026

@rkenna The source ships with the product. Two ways to read it.

The easiest is inside your tenant. Go to System > Customization > Explore > Source Code (SM204570). It's a read-only browser over the C# behind every screen, and it's there on Acumatica's cloud as well as on-prem. It needs customization access, so if you don't see the Customization menu your admin or partner can grant it. A shortcut from any screen is Customization > Inspect Element, click a field, then Actions > View Business Logic Source. That drops you into the graph for that screen.

The other is the installer. Running the Acumatica ERP MSI on any Windows machine (no instance, no license) creates C:\Program Files\Acumatica ERP\Files\App_Data\CodeRepository with the same source as plain .cs files. That's what I read, on build 26.101.

For this question the graph is PX.Objects.IN.INUpdateReplenishmentRules, behind Calculate Replenishment Parameters (IN508500). RetrieveSalesHistory2 pulls the history rows from INItemSiteHistByCostCenterD. PeriodSalesStatInfo.Append is the one line that sums sales, credit memos, transfers out and assembly components per day. MovingAverageModel at the bottom is the average and variance. Safety stock and reorder point come right after the RecalcLeadTime call.

Which transaction types fill which history column is a class called INHistBucket inside PX.Objects.IN.InventoryRelease.INReleaseProcess. Search for it on the Find in Files tab (case sensitive). It's a switch on transaction type and originating module, and it's where drop ships being separate and manual issues not counting comes from.