i have problem sleeping transaction locks on ms sql server 2008
.
sometimes it's not sleeping or when transaction not completed , there real lock. not case.
we have tomcat 6 , java app on it. when i'm doing update in java , i'm trying select updated records - no luck.
if use (nolock) - helps, see correct changed rows, then, after period of time updated rolled back. if update through studio
- works fine, immediate result.
similar situation have in many places of application. example have nightly job doing recalculation of big chunks of data bitfields. , @ end removes old bitfields , copies new bitfields inside. when job completed - rollback happens. tried save these bitfields manually in tmp tables , replaced old new 1 through studio - worked.
all statements , connections closed. verified. , tried these changes in scope of 1 transaction. application running long period of time without troubles, happened.
i tried find out reason , used sp_who, sp_who2, different scripts shows locking queries, did massive monitoring sql server profiler , tried find solution on internet. found error: 1222, severity: 16, state: 18
result of problem, not cause. may i'm moving in wrong direction. me looks changed in sql server configuration , now, reason, holds connection , changes, made in scope of ever. when connection killed - rolled back.
if have ideas appreciate it. in advance help.
update: i've searched , found 1 article:https://support.microsoft.com/en-us/kb/137983 , there option like: if windows nt server computer has closed connection, client process still exists on sql server indicated sp_who, may indicate problem sql server's connection management. in case, should work primary support provider resolve issue.
may mine option. investigate further.
Comments
Post a Comment