Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations MikeeOK on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Locking problem for multi-user server--sql question 1

Status
Not open for further replies.

inspect

Programmer
May 3, 2001
2
US

I have an Access program and placed the tables of the program into sql. The program is being used in a multi-user enviroment. I need to lock the row on the table in a way that if another user accesses the record, they will not be allowed to (begin) editing. I am a self taught access programer and new to sql.
 
Set settings to allow optimistic cursors(I don't know where exactly). John Fill
1c.bmp


ivfmd@mail.md
 
Don't use optimistic locking because it means that I will assume that no one else is using it and therefore can change it. What you need to do is add 1 field to the table with the date and time of the last update on the record. When I actually update the record in the SQL database check if the datetime are the same. If so update the record with new datetime of update. If not get newest data and perform action again.

JNC73.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top