BeyondERP.Newsletter
Menu

Setup step on the Clean up the costing sheet cache page · Cost management

Keep the costing sheet cache small

Remove costing sheet cache records of a given age on a schedule.

Used by
Inventory accountant
Business process
Manage data
Menu item
action:CostSheetCachePurgeJob
Setup steps
1 on this page

How this guide was checked

Checked in Dynamics 365
Version 10.0.49: the menu item, form, table and security, the page.
Recommended values
Based on Microsoft's documentation. A sound starting point to adjust to your own business requirements.
Tests
A ready-to-run test, “Old cache records are removed”, to confirm this setup in your own test environment.
Show what matters for
SETUP GUIDEHow to set it up8 sections. Choose a role to highlight what matters to you.
Everyone

1What it is and why

What it isA periodic task that cleans up the costing sheet cache, which holds costing sheets temporarily to help generate prices.
What you do hereUse this task to delete records in the costing sheet cache that have reached a specified age in days.
ExampleFor example, BEAT runs this job every night with Delete cache records aged (days) set to 7, so costing sheet records built for the week's price calculations are removed and rebuilt the next time a costing sheet is shown.
Clean up the costing sheet cache page in Dynamics 365
The page in Dynamics 365. page title tab to open what to set or check
Functional consultant · Solution architect

2Where it fits

End user · Functional consultant

3How to do it

About the examples: Examples and screenshots in this guide use BEAT, a demo company in a Dynamics 365 test environment. Use your own company's codes and values instead of copying them.

When to run it

When to run itWhen the costing sheet cache has grown large, for example after many BOM calculations or price calculations.
How oftenOn demand, or on a recurring batch schedule that suits how often you run price calculations.
Batch settingsA recurring batch job outside business hours keeps the cache small without manual work.
What the output showsCosting sheet cache records of the specified age or older are removed. Costing sheets are generated again when needed, so a slower first display afterwards is normal.

Source: Microsoft Learn

Setup steps on this page

Keep the costing sheet cache small

Remove costing sheet cache records of a given age on a schedule.

Steps from Microsoft

  1. Go to Cost management > Manufacturing accounting > Clean up > Clean up the costing sheet cache.
  2. Know what is deleted: the CostSheetCache table only holds costing sheets temporarily to help generate prices, so no posted data is affected.
  3. Enter the age in days; cache records that have that age or older are deleted.
  4. Run it in the background on a recurrence if the cache grows quickly, then select OK.
  5. Open a costing sheet for an item or production order afterwards to confirm it is built again without errors.

Source: Microsoft Learn

Fields on the page

FieldWhat it meansExample
Delete cache records aged (days)Records in the cache that are this many days old or older are deleted. Only numbers higher than 0 can be entered.Checked in Dynamics 3657
Use truncate instead of deleteA switch on the dialog, set to Yes in BEAT; while it is on, the age field is unavailable.Checked in Dynamics 365Yes
Run in the backgroundSends the job to the batch framework with a batch group, recurrence and alerts instead of running it while you wait.Checked in Dynamics 365

Common errors and fixes

MessageWhat to do
The age field can't be editedUse truncate instead of delete is set to Yes, which makes the age field unavailable on the dialog. Set the switch to No to delete by age. Checked in Dynamics 365
Functional consultant

4Setup decisions

Setup stepRecommended value and whyDecision, common mistake and test
Keep the costing sheet cache smallSchedule the job as a recurring batch job outside business hours, sized to how often price calculations run.The CostSheetCache table only holds costing sheets temporarily to help generate prices, so old records can go and are rebuilt when needed.How often is the costing sheet cache cleaned?Treating the cache as cost history; it holds no posted data, so a missing cache entry only means the sheet is rebuilt.Test: Old cache records are removed

Feature management and licence

Licence or add-inIn this system 1 role can open this page, among them Inventory accountant.

Checked in Dynamics 365

Solution architect

5Design impact

Can it be undoneReversible: Deleted cache records are rebuilt when a costing sheet is needed.
If you change it laterDeletes old records from the CostSheetCache table; costing sheets are rebuilt on demand. Microsoft Learn
Technical architect

6Technical

Menu itemaction:CostSheetCachePurgeJob Checked in Dynamics 365
Who can open it

1 security role. Select a role to see its duties and privileges.

  • RoleInventory accountantInventCostAccountant
    • DutyMaintain costing sheet cacheCostCachePurgeJobDuty
      • PrivilegeClean up costing sheet cacheCostSheetCachePurgeJobProcess
Roles worked out from Microsoft's standard security setup and checked in a working Dynamics 365 system (version 10.0.49)
Roles to set it up and use itTo use itInventory accountant InventCostAccountantGive people one of these roles. On this system, 1 role can run this page.Checked in Dynamics 365
Developer

7Developer

Open it by URLhttps://<your-environment>/?mi=action:CostSheetCachePurgeJob
Data migrationLoad order: Clean up the costing sheet cache has no data entity in Data management, so it can't be loaded from a file or a configuration template. The cache holds temporary costing sheets that the system rebuilds; nothing is migrated.Checked in Dynamics 365
Everyone

8Sources

To cite this step: CM-CLN-100, Keep the costing sheet cache small. Beyond ERP Atlas Hub. https://www.beyonderp.cloud/atlas/step/CM-CLN-100