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

How to find out which process causes a table lock?

(0) ShareShare
ReportReport
Posted on by

Hey guys,

my customer has the problem, that they have sometimes table locks, but they never know, what they caused.

So now I am thinking about a way, how I can find out what process caused it.

Do you have a strategy, to find out such table locks?

I have the same question (0)
  • Suggested answer
    Marco Mels Profile Picture
    on at

    Hello,

    You may want to use the community postings for this as a starter.

    community.dynamics.com/.../table-locked-by-another-user

    Thanks.

  • Suggested answer
    Mohamad Vajid Profile Picture
    on at

    Hello,

    You can find out which user is blocking by starting SQL Server Management Studio, find the database and run a query with exec sp_who2

    This gives a dump of all current user activity. There is a column called BlkBy, which stands for Blocked By. That gives you the SPID (SQL Process ID) of the person blocking. Find that entry for the BlkBy SPID in this list and that will give you the user who is blocking. You can ask the user what process was running. Hope this helps.

     

  • Community Member Profile Picture
    on at

    Hey,

    I already know this query, the problem is, that I would like to know, who has locked a table also one month or so ago and not in the current session. Is this somehow possible? My customer has such table locks and later they report me, they had again that issue...

  • Suggested answer
    Mohamad Vajid Profile Picture
    on at

    No, you cannot find a locked table a month ago, not to my knowledge.

    You can only try to find out which user is locking a table and then ask the user what process he/she was running.

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 3,143

#2
Jainam M. Kothari Profile Picture

Jainam M. Kothari 1,694 Super User 2025 Season 2

#3
YUN ZHU Profile Picture

YUN ZHU 1,067 Super User 2025 Season 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans