TMyQuery
Multiple use system
Writing an app in which an email address will be used for the login.
Very low security and the owner understands this.
Therefore email addresses must be unique. On a person adding themselves to the database, I need to check to see if that email address exits and if so, deny its duplication. I therefore need to LOCK the table while I do the search. I'm new to SQL, but what I think I need to do is.
Close Query
Open Query in "Read Locked Mode" ... lock it so anyone can read it, but
not write to it
Do my email checking
Do my transaction if no duplicate
Unlock it
I see a Query.LockTable capability but I cannot find the appropriate
value of the lock ... I tried ltReadLock which did not work.
I would appreciate any help.
Thanks,
Bob Watson
Table Locking
-
Challenger
- Devart Team
- Posts: 925
- Joined: Thu 17 Nov 2005 10:53