web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Answered

A worker with a personnel number of was not found

(1) ShareShare
ReportReport
Posted on by 1,419

Hi, 

I keep getting this error message when submitting a document to a workflow: 

Stopped (error): X++ Exception: A worker with a personnel number of was not found.
at SysWorkflowHierarchyProvider-resolve
SysWorkflowHierarchyProvider-resolveHierarchy
SysWorkflowQueue-resume

The workflow uses the managerial hierarchy. There are no other position hierarchy types. 

pastedimage1605604755288v1.png --> Start from has been changed to UserID

- All users have a person attached to them and all employees have a personnel number. 

- Positions have been defined and report to positions as well. "Reports to position"  has been left blank for the last person in the approval chain. 

Any ideas what could be wrong? 

I have the same question (0)
  • Verified answer
    Ramit Paul Profile Picture
    22,797 Most Valuable Professional on at

    Hi,

    This is happening for the last approver whose ID is not correctly setup.

    Can you not add the reports to person and test? it should solve the issue.

  • Verified answer
    André Arnaud de Calavon Profile Picture
    301,075 Super User 2025 Season 2 on at

    Hi CapsLock,

    Is it trying to find a manager for the top position? Have you also set a stop condition to find e.g. the first manager only?

  • CapsLock Profile Picture
    1,419 on at

    Hi Andre, 

    This is how the conditions were setup. So this is dependent on a true/false condition. If false the workflow should point for approval to the person one level above in the hierarchy: 

    pastedimage1605714155750v1.png

    If the condition is true, approval should be directed to the "president". How does the workflow link "president" with D365? Is it because he/she does not report to anyone? 

    pastedimage1605714211070v2.png

    When reaching

    Changing the "Start from" option changes the error message in the following way: 

    With workflow originator:

    Stopped (error): X++ Exception: User not found

     at SysWorkflowHierarchyProvider-resolve

    SysWorkflowHierarchyProvider-resolveHierarchy

    SysWorkflowQueue-resume

    With userID:

    Stopped (error): X++ Exception: A worker with a personnel number of  was not found.

     at SysWorkflowHierarchyProvider-resolve

    SysWorkflowHierarchyProvider-resolveHierarchy

    SysWorkflowQueue-resume

  • Suggested answer
    André Arnaud de Calavon Profile Picture
    301,075 Super User 2025 Season 2 on at

    Hi CapsLock,

    In the past, I had a similar requirement. Then we had a condition to check if the worker was the president. If so, a secretary should perform the approval; otherwise it went to another step to follow the managerial hierarchy.

  • CapsLock Profile Picture
    1,419 on at

    Hi André, thank you very much for sharing it. Would you explain more how do you setup that condition to say who is the president and where do you define that a user is the president?

  • Susanne Kronberg Profile Picture
    29 on at
     you wrote the setup for the last approver ID it not correctly. 
     
    What do you mean? Can you tell me how to set up this ID, so the workflow would run correctly? We are having the same problem, that our workflow stopped. 
     
    Thanks
    Susanne 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Martin Dráb Profile Picture

Martin Dráb 503 Most Valuable Professional

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 434 Super User 2025 Season 2

#3
BillurSamdancioglu Profile Picture

BillurSamdancioglu 278 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans