Results 1 to 2 of 2
  1. #1
    Join Date
    Jul 2003
    Location
    Australia
    Posts
    217

    Unanswered: Record Lock - when is it started ?

    Suppose there is a SQL Server table with a trigger behind it.

    Suppose a client VB (or VBA) program is trying to update a certain record in that table, say record #1, by issuing the update statement:

    RS.update

    My Question:
    When is SQL Server starting to lock that record (record #1) ?
    Right after the RS.update is issued OR after the trigger has been executed ?
    ________________________________

    Thanks in advance.

  2. #2
    Join Date
    Jul 2006
    Posts
    3

    Re:

    Record is immediately locked after rs.Update statement. But since trigger runs in the same transaction as the statement which initiated update, trigger does not get affected by the lock placed. The lock is released after the trigger execution is complete.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •