Stored procedure locking the table

Results 1 to 2 of 2

Thread: Stored procedure locking the table

  1. #1
    Join Date
    Dec 1969

    Default Stored procedure locking the table

    Hi,<BR><BR>I have an ASP application which calls several stored procedures.Application is working fine, but as part of testing we are locking one table and then calling ASP page which will update this table.So now we have a dead lock on the table.And client side i am getting script timeout error on my browser uptil this is fine.But my question is when the script gets timed out will connection to database from Web server be aborted and lock be released or we need to do error handling for this and release the lock?<BR><BR>Any help will be appreciable.<BR>Neelima

  2. #2
    jos Guest

    Default RE: Stored procedure locking the table

    Hi Neelima,<BR>I don&#039;t know if you read my post bellow but I have a problem similar to yours.<BR>I have tested that if the browser gives you a timeout error, if you try from the SQL Server Enterprise to execute this procedure it has still looked the table...<BR><BR>I use two SP to work with a table. The first uses that table only with a SELECT and it makes a lock of kind S, the other SP makes in the same table an INSERT and it makes a lock IX, so this kind of locks are incompatibles and the aplication gives me the error as yours timeout.<BR><BR>The question is:<BR>If I destroy the command object that executes the first SP why when I execute the second SP the table is still locked???<BR><BR>Thanks.

Posting Permissions

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