Page 1 of 1

ADS sp_mgGetLockOwner PROCEDURE

Posted: Tue Jul 01, 2025 1:35 pm
by bobvolz
Hi;
Occasionally I get a call from a user that says they can't open a record because it is locked.
I know ADS and xBase++ have a few functions in ADSMGMT programs that the user can trace the owner and they work fine.
I was just wondering if anyone skipped all the browsers et al and just called the sql procedure sp_mgGetLockOwner
directly from within theIR function trying to lock the record and then displaying the user name and machine that has the record locked.
This would help quite a bit.
I still use ADS because it works and doesn't fail me on updates and indexes.
I wish support continued.
Bob Volz

Re: ADS sp_mgGetLockOwner PROCEDURE

Posted: Tue Jul 01, 2025 10:21 pm
by Tom
Hi, Bob.

We also still support and use the ADS for the same reasons. We still get licences from SAP, which is not easy nowadays.

We built an own "management console" inside our application and do use some SQL there, but not for the locks. This uses the function AdsMgGetLockOwner() from ADSMG.DLL (full source in ..\Documents\Xbase++\source\samples\adsdbe\console). We get the connection names (computer names) with that, but not the names of the users. Besides, this will only work if you use a root dictionary.

Re: ADS sp_mgGetLockOwner PROCEDURE

Posted: Wed Jul 02, 2025 6:36 am
by bobvolz
Thanks Tom. I use the ADSMGMT program that Roger created. It's just a bit cumbersome to use for the average user.
All I was trying to do was show the user who was trying to access the record the name of the user or pc that had it locked.
Perhaps I'll just give them the Ads Mgmt console. I took the 'killuser ' option out .
Bob Volz