Solved

How to determine if a LAN user is editing the current record

Posted on 2002-03-12
3
133 Views
Last Modified: 2010-05-02
Is there a way to tell if myself and another user are editing the same record across a LAN? I am using the Data control.
0
Comment
Question by:Gmoney
  • 2
3 Comments
 
LVL 3

Accepted Solution

by:
Rem earned 50 total points
ID: 6859835
Yes,

If you're using pessimistic locks, you won't be able to update.

Try to avoid this situation though. It's fairly easy to add a field (flag) set to 'true' when a user opens the record. Once this flag is 'true', no second user can open the record if your query specifies the value of the flag.

Bye

Rem
0
 
LVL 6

Expert Comment

by:VK
ID: 6859886
Hello Gmoney !

Yes there are different ways depending on your configuration: OS, Database, ....

If your Database supports locking single records like
SQL-Server 7.0 or higher for example you haven't much to do.

If your Database doesn't support single record locking.
Access for example locks 2K pages an cannot lock single records. So you will get a conflict although the 2 users are editing different records if the pages have an intersection.

An approach would be having an extra locking table where you store the current lockings. However you have to do some clean-up process if you find 'too' old lockings.
They could have been remained after system crash or abnormal program termination.

V.K.
0
 
LVL 3

Expert Comment

by:Rem
ID: 6860874
Thanks for the points, and glad to have been of help.

Bye

Rem
0

Featured Post

Are your AD admin tools letting you down?

Managing Active Directory can get complicated.  Often, the native tools for managing AD are just not up to the task.  The largest Active Directory installations in the world have relied on one tool to manage their day-to-day administration tasks: Hyena. Start your trial today.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
JSON Response and request in VB6 application 11 418
using Access 8 68
passing parameter in sql procedure 9 63
Need Nag Screen for Reboot if system up time is over 14 days 12 48
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question