Share via

com.microsoft.sqlserver.jdbc.SQLServerException: Cannot continue the execution because the session is in the kill state.

Scott Huscroft 20 Reputation points
2025-09-21T14:46:58.2133333+00:00

I am reaching out for assistance regarding an error we are experiencing in our SQL Server environment. The error message is as follows:

com.microsoft.sqlserver.jdbc.SQLServerException: Cannot continue the execution because the session is in the kill state.

  • Environment: Microsoft SQL Server
  • Driver: Microsoft JDBC Driver for SQL Server
  • Error Context: This error occurs when attempting to execute queries against the database. Once the session reaches this state, subsequent execution attempts fail.
  • Impact: The issue interrupts database operations on critical processes.

We ran rebuilds and CHECKDB and get this error....

Msg 211, Level 23, State 246, Line 1

Corruption in database ID 140711718551557, object ID 60 possibly due to schema or catalog inconsistency. Run DBCC CHECKCATALOG.

Then we run the DBCC CHECKCATALOG and it shows no errors.

Could you please provide guidance on the root cause of why a session enters the “kill state” and recommended steps to recover from or prevent this state.

Thank you very much for any assistance on this critical issue.

SQL Server | SQL Server Transact-SQL

Answer accepted by question author

Erland Sommarskog 134.7K Reputation points MVP Volunteer Moderator
2025-09-21T18:31:50.6133333+00:00

I asked for the full log output, because I was confused by the database ID, thinking that could suggest something about root cause for the corruption. But when I googled, I found a StackOverflow thread with this error message and a similar bogus ID. In their case, though, DBCC CHECKCATALOG clearly pointed out an error in the system table in question. (Object id = 60 is sysobjvalues.) So I am leaning towards that the bogus ID is an issue in DBCC itself.

The normal recommendation when you have corruption is to restore a clean backup and apply transaction logs. Since corruption is due to malfunctioning hardware (including drivers), the corruption is typically not recorded in the transaction log. But I am less sure that we can blame inconsistency in the system catalog on the hardware, so that may not help.

And very clearly, you have an issue since the application is erroring out. I would recommend you to open a support case. I am not sure that CSS is willing to track down where the metadata corruption lies, but if they are, they can also give you statements to run to correct the system catalog. And if you are going to make changes to the system tables, it is quite important that you do so only by recommendation from Microsoft, or else you would render your database unsupported.

Was this answer helpful?

0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Scott Huscroft 20 Reputation points
    2025-09-22T13:50:48.1033333+00:00

    thank you very much! I really appreciate your help with this. Have a good day!

    Was this answer helpful?

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.