Next beta will have record locks.

Ruslan Zasukhin sunshine at public.kherson.ua
Tue Jul 1 15:20:54 CDT 2003


on 7/1/03 14:16, erne at ernestogiannotta at tiscalinet.it wrote:

> so if we call a cursor as Locked, all its records get the locked status

> Can't we lock/unlock on a record basis?

Erne, 

EACH cursor always lock its records. EACH cursor. ALWAYS.
You can just specify READ ONLY lock, or READ WRITE lock.

You cannot manually set remove locks.
This work do cursor

> What happens if another call try to build a Locked cursor that includes
> records already Locked?

Yes good question. 
Was added also new error code: kCannotSetLock.

So in case if cursor cannot establish lock at least for one its record, then
you get error and need repeat cursor building little later.

For now, we have NOT implement any timeout. You get immediate refuse in case
a record is locked by somebody else.

> e.g.
> 
> c1 = SqlSelect(query, kClient, kWrite, kRandom)
> 
> c1 has 3 records recid 1,2,3
> 
> c2 = SqlSelect(otherquery, kClient, kWrite, kRandom)
> 
> c2 has 3 records recid 3,4,5
> 
> you see? recid 3 is already locked
> what we expect now?

Error 'kCannotSetLock' and NO cursor.

-- 
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