Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /home/lsp4you/public_html/connect.php on line 2 LSP4YOU - Learner's Support Publications

Locks and Types of Locks

Transaction uses locks to deny access to other transactions and so prevent incorrect updates.

Types of Locks:
  • Binary Lock: This locking mechanism has two states for a data item.
    • Locked
    • Unlocked
  • Multiple-mode Lock: In this locking type each data item can be in three states.
    • Read locked or shared locked
    • Write lock or exclusive lock
    • Unlocked