-----------------------------------------------------------
New Message on BDOTNET
-----------------------------------------------------------
From: LovedJohnySmith
Message 2 in Discussion
Hi Vinay,
Have a Good Day!!!
By default, Sybase uses optimistic
locking (that is, Sybase sets the Default record locking option to No locks
similiar to Access). This allows two or more users to edit the same record
at the same time. You must change this default to pessimistic locking (that
is, set the Default record locking option to Edited record). Optimistic
locking only enforces a lock when one user tries to save a change after
another user has already changed the same record. Optimistic locking overrides
record-level locking, even if the Open databases using record-level locking
checkbox has been selected. Record-level locking is invoked when pessimistic
(that is, the Default record locking option is set to Edited record) is
selected.
When you use page-level locking(rather than record-level locking), multiple
records can become locked while a user is editing a single record. In other
words, all records that fit within the 4 kilobyte (4096 byte) page will
be locked, even though only one of the records within that page is being
edited.
With record-level locking, however, if a user edits any one record in a
table, other users are able to edit any other record, except that one.
But this is only true when both pessimistic and record-level lockign has
been set within the Sybase Options dialog box.
The following steps show how record-level locking appears to not be working.
Steps to Reproduce Behavior
1. One
the same computer, start Sybase twice, and open the sample database in
each instance of Access.
2. In
the first instance of Access, on to the Tools menu, click Options,
and then click the Advanced tab.
3. Make
sure the Open databases using record-level locking check box is selected,
make sure Default record lock is set to No locks (optimistic lock), and
then click OK.
4. Repeat
steps 2 and 3 for the second instance of Access.
NOTE: If you had to click to select the Open databases using record-level
lock check box in either instance, close that instance, and then reopen
the sample database.
5. Open
the any table(eg., Category) in both instances.
6. In
the first instance, for CategoryID 4, change the Description box from Cheeses
to Cheeses and Eggs. Do not save the change.
7. Edit
the same record in the second instance, but change the value to Cheeses
and Milk. Note that although record-level lock is invoked, you are
allowed to edit the value in both instances. If you now save the change
in the second instance, the first instance will generate the following
Write Conflict error if you try to save its change:
This record has been changed by another user
since you started
editing it. If you save the record, you will overwrite the changes
the other user made.
Copying the changes to the clipboard will let you look at the values
the other user entered, and then paste your changes back in if you
decide to make changes.
I hope this will fulfill ur requirements.
thanx,
Regards,
smith
Johnson Smith
Tata Consultancy Services Limited
Mailto: [EMAIL PROTECTED]
Website: http://www.tcs.com
-----------------------------------------------------------
To stop getting this e-mail, or change how often it arrives, go to your E-mail
Settings.
http://groups.msn.com/BDOTNET/_emailsettings.msnw
Need help? If you've forgotten your password, please go to Passport Member Services.
http://groups.msn.com/_passportredir.msnw?ppmprop=help
For other questions or feedback, go to our Contact Us page.
http://groups.msn.com/contact
If you do not want to receive future e-mail from this MSN group, or if you received
this message by mistake, please click the "Remove" link below. On the pre-addressed
e-mail message that opens, simply click "Send". Your e-mail address will be deleted
from this group's mailing list.
mailto:[EMAIL PROTECTED]