Need help for lock the row 
Author Message
 Need help for lock the row

I have open the recordset (dbOpenDynaset) which contain one row only.
I found it will lock several rows after use Edit method. How can I lock
that row only??

Thanks a lot



Wed, 12 May 1999 03:00:00 GMT  
 Need help for lock the row

Quote:

> I have open the recordset (dbOpenDynaset) which contain one row only.
> I found it will lock several rows after use Edit method. How can I lock
> that row only??

> Thanks a lot

I assume you are using Access.

Access uses page locking which locks 2k at a time.  If your records are
less than 1k then Access will lock more than one record.

The only way out of it that I know of is to make sure that every record
in your table is larger than 1k. Depending on the current size of your
records, how many you have, available storage this is probably going
overboard.

Peter



Thu, 13 May 1999 03:00:00 GMT  
 Need help for lock the row

Quote:

> I have open the recordset (dbOpenDynaset) which contain one row only.
> I found it will lock several rows after use Edit method. How can I lock
> that row only??

> Thanks a lot

If you're using Access - you can't. You can try the optimistic locking
method:

        myrecordset.lockedits = false

Which may work a little better for you.

        Jim



Fri, 14 May 1999 03:00:00 GMT  
 Need help for lock the row

Quote:


>> I have open the recordset (dbOpenDynaset) which contain one row only.
>> I found it will lock several rows after use Edit method. How can I lock
>> that row only??

>> Thanks a lot

>I assume you are using Access.

>Access uses page locking which locks 2k at a time.  If your records are
>less than 1k then Access will lock more than one record.

>The only way out of it that I know of is to make sure that every record
>in your table is larger than 1k. Depending on the current size of your
>records, how many you have, available storage this is probably going
>overboard.

>Peter

Peter,

You said:

Quote:
> The only way out of it that I know of is to make sure that every record in your table is larger than 1k.

Why only 1K ?
If my record size is at bigger 1K in length, say 1k+a few bytes, will
my page locks then not go onto the next records ?

I'm new to this page vs record locking stuff.
Thanks.



Sat, 15 May 1999 03:00:00 GMT  
 Need help for lock the row

Because Access will not split a record over multiple pages.  Therefore, if
your record is larger than 1K, it will occupy the page all by itself.
Therefore, the page lock will affect only one row.

--- Nick Malik
VB MVP
www.malikinfo.com

Quote:
> Peter,

> You said:
> > The only way out of it that I know of is to make sure that every record

in your table is larger than 1k.
Quote:

> Why only 1K ?
> If my record size is at bigger 1K in length, say 1k+a few bytes, will
> my page locks then not go onto the next records ?

> I'm new to this page vs record locking stuff.
> Thanks.



Sun, 16 May 1999 03:00:00 GMT  
 
 [ 5 post ] 

 Relevant Pages 

1. Help, ADO row lock

2. Row Level Locking Help???

3. Row Level Locking Help???

4. need to preselect and highlight row 20 in 6 row unbound msFlexgrid

5. Need Help on DataGrid Row Selector

6. Needed help with tables missing rows..

7. AGAIN Cant insert a row WHY? NEED HELP

8. Need Help on DataGrid Row Selector

9. Help needed in refreshing the MS-DBGrid after deleting row

10. Help needed filtering rows In Crystal Reports 8

11. AGAIN Cant insert a row WHY? NEED HELP

12. AGAIN Cant insert a row WHY? NEED HELP

 

 
Powered by phpBB® Forum Software