试图通过发出"sp_reset_connection"来理解Sql Profiler的含义.
我有以下,"exec sp_reset_connection"行后跟BatchStarting和Completed,
RPC:Completed exec sp_reset_connection
SQL:BatchStarting SELECT [c].[TestID] AS [TestID], [c].[Description] AS [Description] FROM [dbo].[Test] AS [c]
SQL:BatchCompleted SELECT [c].[TestID] AS [TestID], [c].[Description] AS [Description] FROM [dbo].[Test] AS [c]
Run Code Online (Sandbox Code Playgroud)
基本上第一行"exec sp_reset_connection"意味着整个过程(我的连接被打开,选择stmt运行,然后连接关闭并释放回池)刚刚发生?或者我的联系仍处于开放阶段.
而且,为什么sp_reset_connection在我自己的select语句之前执行,不应该在用户的sql之后复位吗?
我想知道有什么方法可以更详细地了解连接何时打开和关闭?
通过查看"exec sp_reset_connection",这是否意味着我的连接已关闭?
sql-server database-connection sql-server-profiler sp-reset-connection