|
-
May 4th, 2007, 12:47 PM
#1
Thread Starter
Member
[RESOLVED] row lock
Hi ,
I want to connect to a database and update a certain row .. then lock it.
when trying to access the row again I want to prompt the user he cant because its locked..
thank you in advance..
-
May 4th, 2007, 12:57 PM
#2
Re: row lock
Add field called Updated.
Before allowing any updates to the record, check the field. If it is empty, allow the update.
After the first update, put "Yes" in that field.
Now, the next time someone goes to update that record they won't be able to because of their field entry.
But, then again, you wouldn't be able to update it either.
No one could.
Is that what you want?
-
May 4th, 2007, 01:03 PM
#3
Thread Starter
Member
Re: row lock
thank you HACK,
are you telling me to add a column to every row holding a boolean value telling if the row has been updated or not?
-
May 4th, 2007, 01:06 PM
#4
Re: row lock
I'm saying add a field to your table.
-
May 4th, 2007, 01:16 PM
#5
Thread Starter
Member
-
May 4th, 2007, 01:21 PM
#6
Re: row lock
You are welcome. 
If you consider this resolved, you could help us out by pulling down the Thread Tools menu and click the Mark Thread Resolved menu item. That will let everyone know that you have your answer.
Thank you.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|