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

Facing an error in job queue

(0) ShareShare
ReportReport
Posted on by 234
I have a job queue which basically fetches data from third-party software and stores in business central. This table in businesss central has around 439 fields so this job queue takes a lot of time. Meanwhile, we are storing all fetched data from API call inside json buffer table. But for up to 5000 records, it is running fine but for more than that it is showing following error:
We can't save your changes right now, because a record in table 'JSON Buffer' is being updated in a transaction done by another session.

You'll have to wait until the other transaction has completed, which may take a while. Please try again later.


We have also increased job timeout to 18 to 23 hours still it is failing within 11 hours. No user has been working on the table as well.



I have the same question (0)
  • Judy Profile Picture
    Microsoft Employee on at
    Hi,
     
    Have you tried to restart the environment? Please restart the Job related and restart the API rest and run it again to see if the error occurred.
    The following Document help you troubleshoot issues with Business Central so that you can gather information about a given problem, identify the cause of the problem, and eventually implement a sustainable solution
     
     
     
    Best Regards,
    Judy
  • Community member Profile Picture
    6 on at
    Hi,
    ÃŒs it possible to do pageing in your API and read <5K records at a time to process and store it and use commit before u call for next pageing.
     
     
  • Suggested answer
    KasparsSemjonovs Profile Picture
    4,774 Super User 2025 Season 2 on at
    Sankar P is correct. Paging should solve the issue. 
    It is know that Business Central limits queries or records to 5000. Similar as You cannot export to excel more than 5000 lines. In NAV it was possible to change this limit in ClientUserSettings file, but for BC not sure if it can be done via CMDLETs. You can explore in this direction.
  • Pragya752 Profile Picture
    234 on at
    I have set one record per page only.
     
    Pagingobject.Add('PageIndex', PageIndex);
            Pagingobject.Add('PageSize', LSQSetp.PageSize);
            JObject.Add('Paging', Pagingobject);
     JObject.Add('Columns', IncludeCSVObject);
            SortingObject.Add('ColumnName', 'CreatedOn');
            SortingObject.Add('Direction', 1);
            JObject.Add('Sorting', SortingObject);
      if Response.IsSuccessStatusCode then begin
                Response.Content().ReadAs(ResponseText);
                //Message(ResponseText);
                JsonBuffer.Reset();
                if JsonBuffer.FindSet() then
                    JsonBuffer.DeleteAll();
                jsonBufferTemp.ReadFromText(ResponseText);
                if jsonBufferTemp.FindSet() then
                    repeat
                        JsonBuffer := jsonBufferTemp;
                        JsonBuffer.Insert();
                    until jsonBufferTemp.Next() = 0;

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,606

#2
YUN ZHU Profile Picture

YUN ZHU 931 Super User 2025 Season 2

#3
Jainam M. Kothari Profile Picture

Jainam M. Kothari 773 Super User 2025 Season 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans