SQL Server Temp Tables and Connection Pooling

后端 未结 6 1759

I have a multi-user ASP.NET app running against SQL Server and want to have StoredProcA create a #temptable temp table - not a table variable - to insert some data, then bra

6条回答
  •  囚心锁ツ
    2020-12-14 07:05

    Connection pooling (with any modern version of SQL Server) will call sp_reset_connection when reusing a connection. This stored proc, among other things, drops any temporary tables that the connection owns.

提交回复
热议问题