johnson1
asked on
sql executing timeout
Hello,
In SQL server manager I was deleting rows from a table. When I returned an hour later it was still executing even though the rows that should be deleted were only about 2000.
While it was executing other calls to the database timed out, so that users could not login to my website. The reason may be that it could not delete a row because of foreign key.
Why did it continue to execute and not stop? Can I change the sql settings so this does not happen again? I am using sql 2008.
In SQL server manager I was deleting rows from a table. When I returned an hour later it was still executing even though the rows that should be deleted were only about 2000.
While it was executing other calls to the database timed out, so that users could not login to my website. The reason may be that it could not delete a row because of foreign key.
Why did it continue to execute and not stop? Can I change the sql settings so this does not happen again? I am using sql 2008.
ASKER
Thank you Surendra. Is it possible to have sql stop executing if it exceeds certain timelimit?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you
The most probables one are listed below in the high to low probablity factor
1) The table that you are deleted is locked by some other user
2) An explict transasction is opened by an user in another SSMS window and left it open
3) The Forieghn key constraint table has a huge data in the underlying tables probably millions
4) the foreighn key constraint table is locked...