Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Dynamics 365 general forum

Built in autonumber field increased even when record creation fails

(1) ShareShare
ReportReport
Posted on by

Hi!

We have a workflow that triggers when a contact record is created. This workflow then implements a custom made auto number field that is increased with each new contact. A decision was made to replace our own implementation of an autonumber field to use the built in feature available in version 9. I added an extra step in the workflow to create a record with the built in autonumber. I used Xrmtoolbox autonumber manager to set the seed and everything. I seemed to work good in the manual tests. But as soon as a non-admin user created a contact the workflow failed; because I forgot to update the permissions to create the new custom entity (we use a specific entity for the autonumber but it should not matter with regards to my question). After I fixed the permissions and the user again tried to create a contact it worked, no fails in the workflow. But at this point the built in autonumber and our own implementation differed by the X number of times the user failed the workflow. It seems as if the autonumber increases even though the record is never created. Is this the intended functionality or is this a bug?

Just to get some things out of the way: I am sure no records (with built in autonumber) were created and remained after the workflow. I am also sure I set the seed correctly. 

So in short: If user doesn't have permission to create a custom entity (in my case) and a workflow run with the user's permissions tries to create the custom entity and the creation fails, the built in autonumber still increases in value.

Thanks in advance!

  • LuHao Profile Picture
    LuHao 40,876 on at
    RE: Built in autonumber field increased even when record creation fails

    Hi Fredruskus,

    This looks like the condition of the workflow has not been executed successfully.

    Could  you provide a screenshot of your workflow setting?

    Hope this helps.

    Best Regards,

    Lu Hao

  • a33ik Profile Picture
    a33ik 84,325 Most Valuable Professional on at
    RE: Built in autonumber field increased even when record creation fails

    Hello,

    As for me it looks like a bug. I don't think this is show-stopper but anyway I would recommend to post the idea on the ideas portal - experience.dynamics.com/ideas and open a ticket with Microsoft if it causes issues with your implementation.

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

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Coming on 11/8!

In our never-ending quest to help the Dynamics 365 Community members get answers faster …

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,516 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,430 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans