Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 139293
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T07:24:32+00:00 2026-05-11T07:24:32+00:00

sp_reset_connection seems to be called by SQL Server connection pooling, to ensure that connections

  • 0

sp_reset_connection seems to be called by SQL Server connection pooling, to ensure that connections reused from the pool have most of their settings reset. Does anyone know exactly what it does and doesn’t do though?

eg I see from this post that it doesn’t reset the transaction isolation level

  • 1 1 Answer
  • 1 View
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T07:24:33+00:00Added an answer on May 11, 2026 at 7:24 am

    Data access API’s layers like ODBC, OLE-DB and SqlClient call the (internal) stored procedure sp_reset_connection when re-using a connection from a connection pool. It does this to reset the state of the connection before it gets re-used.

    There does not appear to be official documentation on what things get reset, but here is an unofficial list.

    sp_reset_connection resets the following aspects of a connection:

    • It resets all error states and numbers (like @@error)
    • It stops all EC’s (execution contexts) that are child threads of a parent EC executing a parallel query
    • It will wait for any outstanding I/O operations that is outstanding
    • It will free any held buffers on the server by the connection
    • It will unlock any buffer resources that are used by the connection
    • It will release all memory allocated owned by the connection
    • It will clear any work or temporary tables that are created by the connection
    • It will kill all global cursors owned by the connection
    • It will close any open SQL-XML handles that are open
    • It will delete any open SQL-XML related work tables
    • It will close all system tables
    • It will close all user tables
    • It will drop all temporary objects
    • It will abort open transactions
    • It will defect from a distributed transaction when enlisted
    • It will decrement the reference count for users in current database; which release shared database lock
    • It will free acquired locks
    • It will releases any handles that may have been acquired
    • It will reset all SET options to the default values
    • It will reset the @@rowcount value
    • It will reset the @@identity value
    • It will reset any session level trace options using dbcc traceon()

    sp_reset_connection will NOT reset:

    • Security context, which is why connection pooling matches connections based on the exact connection string
    • If you entered an application role using sp_setapprole, since application roles can not be reverted
    • The transaction isolation level
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Trying to understand what Sql Profiler means by emitting sp_reset_connection. I have the following,
So I have a for loop that does an iteration of a SQL stored
I need to run a sql script that is in a file from my
I have a typical scenario that I'm struggling with from a performance standpoint. The
Based on information I have read about the exec sp_reset_connection which appears in SQL
The sp_password sproc in sql server 2000 only required membership in the db_accessadmin db_securityadmin
I have an SP that takes 10 seconds to run about 10 times (about
I have a SP that has the following algorithm. IF <SomeCondition> BEGIN SELECT *
I have the need to run a .bat file to run a SQL command
I've just migrated from SQL2000 to SQL2008 and I have started getting an execute

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.