[Logo]
Forums Register Login
lock & read or just read?
Hi all,

My assignment has the following comment on the lock(int) method: Locks a record so that it can only be updated or deleted by this client.. So what I am thinking is to only use the physical locking (ie locking on the database file) when reading a record. An additional record locking (along with physical locking) will be only used when updating/deleting a record.

DBClient class



Data class:


Do you think it is an appropriate approach to the read method?


[ December 08, 2005: Message edited by: Alex Sharkoff ]
Hi Alex,

I think that is suitable for the read method.

Regards, Andrew
thanks a lot, Andrew.

Why should I lose weight? They make bigger overalls. And they sure don't make overalls for tiny ads:
Why should you try IntelliJ IDEA ?
https://coderanch.com/wiki/696337/IntelliJ-IDEA


This thread has been viewed 700 times.

All times above are in ranch (not your local) time.
The current ranch time is
Aug 17, 2018 02:06:55.