Saturday, January 28, 2012

Jet OLE DB Database Locking Mode

The Jet OLE DB Database Locking Mode property can be set to any of the following values:
Page-level Locking: 0 - Meaning that the entire page (or Excel sheet) will be locked when someone will edit that page or excel sheet
Row-level Locking : 1 - Meaning that only particular row which is being edited at the moment will be locked.

Obviously a better option is row-level locking.

Note 1
A database can only be open in one mode at a time. The first user to open the database determines the locking mode to be used while the database is open.

Note 2
If Excel is as database, it must be set to a shared mode. Navigate to Preview > Share Workbook and check in the  "Allow changes" check box.

No comments:

Post a Comment