V4WS need to use semaphores when READ from table in case cause simultaneous indexing?

Ruslan Zasukhin sunshine at public.kherson.ua
Sat Nov 27 13:52:56 CST 2004


On 11/27/04 1:03 PM, "Steven" <srt at bigpond.net.au> wrote:

>>> QUESTION 1: Can I use METHOD 1 safely with V4WS on Mac OS 9, or do I
>> need
>>> to use METHOD 2 to avoid problems with simultaneous indexing?
>> 
>> I think you can.
>> 
>> Again. Valentina have record level locks.
>> So if cursor of first user lock some records, then second user cannot
> access
>> them until first unblock them.
> 
> 
> V4WS now has record level locks? Since when?? How do I lock records in V4WS
> (give example please)?

More than year.

Since 1.9.8 release.

Valentina lock records self when build cursor.

In the Db.SqlSelect() you should see 3 new parameters to control HOW
Valentina lock records of a new cursor. Please check docs.


>> But I still do not catch why you do care about indexes?
>> You think that they can work in other thread?
>> This is true only for VAPP.
>> V4WS index in the same thread.
> 
> 
> I am worried about two simultaneous threads in V4WS both trying to update
> the same index. Do I need to worry about this or does V4WS take care of
> this automatically?

V4WS and WS CANNOT update it really simultaneous,
Because OS 9 is cooperative.

If one thread start add record, then it will not return until it finish.

> In other words, can I use METHOD 1 safely?

I think yes

-- 
Best regards,
Ruslan Zasukhin      [ I feel the need...the need for speed ]
-------------------------------------------------------------
e-mail: ruslan at paradigmasoft.com
web: http://www.paradigmasoft.com

To subscribe to the Valentina mail list go to:
http://lists.macserve.net/mailman/listinfo/valentina
-------------------------------------------------------------




More information about the Valentina mailing list