BeyondERP.Newsletter
Menu

Setup step on the Work user session log cleanup page · Warehouse management

Keep work user sessions for the last shifts

Use this job to delete work user session records older than the hours you keep.

Used by
Warehouse planner
Business process
Manage warehouse operations
Menu item
action:WHSSessionLogCleanupServiceDoCleanup
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, “Clean work user sessions”, 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 deletes work user session log records.
What you do hereUse this task to delete work user session records older than the number of hours you choose to keep.
ExampleFor example, BEAT runs this job every night with Number of hours to keep = 48, so supervisors can still see the sessions of the last two shifts on Work user sessions.
Work user session log cleanup 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

Business processManage warehouse operations
Menu pathWarehouse management › Periodic tasks › Clean up › Work user session log cleanup
Set up firstWorker Microsoft Learn
Used next byWork user sessions Microsoft Learn
Related pagesMobile device activity log cleanup Microsoft Learn
In this process Keep mobile device activity logs for two weeks · Clean wave label records of finished shipments
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 work user session records pile up and only recent sessions matter.
How oftenRecurring, for example daily, because it keeps hours, not days.
What the output showsDeleted work user session records older than the hours you keep.

Source: Microsoft Learn

Setup steps on this page

Keep work user sessions for the last shifts

Use this job to delete work user session records older than the hours you keep.

Steps from Microsoft

  1. Go to Warehouse management > Periodic tasks > Clean up > Work user session log cleanup.
  2. Enter the number of hours of work user session records to keep; older WHSWorkUserSessionLog records are deleted.
  3. Note that while the cleanup runs, Work user sessions may show no history.
  4. Afterwards, open Inquiries and reports > Mobile device logs > Work user sessions to see what is left.

Source: Microsoft Learn

Fields on the page

FieldWhat it meansExample
Number of hours to keepWork user session records older than this number of hours are deleted from WHSWorkUserSessionLog. The dialog opens with 0.Microsoft Learn 48

Common errors and fixes

MessageWhat to do
Work user sessions shows no historyThe page may show no history while the cleanup runs. Look again after the job finishes. Microsoft Learn

Test checklist

  1. Work user sessions only shows recent sessions.

Source: Microsoft Learn

Functional consultant

4Setup decisions

Setup stepRecommended value and whyDecision, common mistake and test
Keep work user sessions for the last shiftsRun it nightly with 48 hours, enough to review the last two shifts.The retention is in hours, so a value meant as days removes almost everything.How many hours of work user sessions are kept?Entering 30 meaning 30 days, which keeps only 30 hours.Test: Clean work user sessions

Feature management and licence

Licence or add-inWarehouse management is part of the Dynamics 365 Supply Chain Management licence. In this system 1 role can open this page, among them Warehouse planner.

Microsoft Learn

Solution architect

5Design impact

Shared or per companyPer company: the job deletes session records of the legal entity it runs in. Microsoft data model
Can it be undoneIrreversible: Deleted session logs can't be restored.
If you change it laterDeletes work user session records older than the hours you keep from WHSWorkUserSessionLog; it keeps hours, not days. Microsoft Learn
Technical architect

6Technical

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

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

  • RoleWarehouse plannerWHSWarehousePlanner
    • DutyMaintain warehouse planningWHSWarehousePlanningMaintain
      • PrivilegeWork user session log cleanupWHSSessionLogCleanupServiceProcess
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 itWarehouse planner WHSWarehousePlannerGive 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:WHSSessionLogCleanupServiceDoCleanup
Data migrationLoad order: Work user session log cleanup has no data entity in Data management, so it can't be loaded from a file or a configuration template. The job only deletes old records; there is nothing to migrate. Set up the same recurring job in the new environment.Microsoft Learn
Everyone

8Sources

To cite this step: WM-JOB-210, Keep work user sessions for the last shifts. Beyond ERP Atlas Hub. https://www.beyonderp.cloud/atlas/step/WM-JOB-210