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 :
Small and medium business | Business Central, N...
Suggested Answer

Insert Sales Record with API

(1) ShareShare
ReportReport
Posted on by
Hi, 
We got a question from a SAAS client about the limitations of inserts of Sales Documents through various API's. Their concern is that deadlocks will occur.

Question:
What is that maximum amount of inserts that BC can handle on one record before a deadlock will occur?
If we have Three API's that will insert randomly at anytime into Sales Header & Sales Lines with approximatly 3000 records each per day will this cause deadlocks?

The proposed solution is to give the API that will have the most inserts its own buffer tables (an exact replica of the Sales Header and Lines) and then use a job queue to systematically import the data, but I'm not convinced that it is necesarry.

Thanks 
I have the same question (0)
  • Suggested answer
    Tech-Lucky Profile Picture
    1,267 Super User 2025 Season 2 on at
    check this out might be usefull for you 

    Database locking caused by web service calls

    Don't insert child records belonging to the same parent record in parallel. This condition causes locks on both the parent table and the integration record table because parallel calls try to update the same parent record. The solution is to wait for the first call to finish or use OData $batch, which will make sure calls get run one after another.

  • Suggested answer
    Kamal Khakhkhar Profile Picture
    1,282 on at
    Hii There,
    As per your requirement you can try this like below mentioned. Thank you, Yun Zhu.
     
    https:/yzhums.com/6117/
     
    Thank You.
    Kamal Khakhkhar

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 > Small and medium business | Business Central, NAV, RMS

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 2,238

#2
YUN ZHU Profile Picture

YUN ZHU 773 Super User 2025 Season 2

#3
Sumit Singh Profile Picture

Sumit Singh 630

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans